:root{color-scheme:light;--bg:#f5f6f8;--surface:#fff;--soft:#f9fafb;--text:#1f2937;--muted:#6b7280;--line:#e1e6ee;--line2:#eef1f5;--accent:#1d4ed8;--bad:#b42318;--ok:#047857}*{box-sizing:border-box}html,body{max-width:100%;overflow-x:hidden}body{margin:0;background:var(--bg);color:var(--text);font-family:Arial,'Apple SD Gothic Neo','Malgun Gothic',sans-serif}a{color:var(--accent);text-decoration:none}a:hover{text-decoration:underline}.topbar{min-height:58px;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:0 24px;background:#fff;border-bottom:1px solid var(--line);position:sticky;top:0;z-index:10}.brand{font-size:20px;font-weight:800;color:var(--text)}.topbar nav{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.topbar form{margin:0}.page{width:min(1280px,100%);margin:0 auto;padding:24px 16px 56px}.flash{margin-bottom:14px;padding:12px 14px;border:1px solid #ead58f;background:#fff8dc;border-radius:8px}button,.button{min-height:36px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--text);font-weight:800;padding:8px 12px;cursor:pointer;white-space:nowrap}.button.primary,button.primary{background:var(--accent);border-color:var(--accent);color:#fff}button:disabled{opacity:.55;cursor:not-allowed}input,textarea,select{width:100%;min-width:0;border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--text);font:inherit;font-size:14px;padding:9px 10px}textarea{resize:vertical;line-height:1.55}.hero{min-height:360px;display:flex;align-items:center}.hero h1{font-size:44px;margin:8px 0 12px}.hero p{color:var(--muted);font-size:17px;line-height:1.7}.actions{display:flex;gap:10px;margin-top:22px;flex-wrap:wrap}.panel.narrow{max-width:440px;margin:42px auto;padding:22px;background:#fff;border:1px solid var(--line);border-radius:8px}.form{display:grid;gap:14px}.form label{display:grid;gap:8px;font-weight:800}.eyebrow{margin:0;color:#0f766e;font-size:12px;font-weight:900;text-transform:uppercase}.page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:14px}.page-head h1{margin:4px 0 0;font-size:29px}.head-count{padding:8px 12px;border-radius:999px;background:#111827;color:#fff;font-weight:900}.metric-row{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;margin-bottom:14px}.metric{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0;padding:11px 12px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--text)}.metric strong{font-size:22px}.metric span{font-size:13px;color:var(--muted);font-weight:800}.metric.active{border-color:var(--accent);box-shadow:0 0 0 2px rgba(29,78,216,.08)}.control-panel{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(300px,.6fr);gap:10px;margin-bottom:10px}.control-block,.fold-panel,.table-panel{min-width:0;background:#fff;border:1px solid var(--line);border-radius:8px;padding:14px}.control-block h2,.section-title h2{margin:0;font-size:18px}.control-block h2{margin-bottom:10px}.collect-form{display:grid;grid-template-columns:minmax(220px,1fr) 118px 88px 100px auto;gap:8px}.quick-add-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px}.fold-panel{padding:0;margin-bottom:12px}.fold-panel details{padding:13px 14px}.fold-panel summary{cursor:pointer;font-weight:900}.bulk-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;margin-top:10px}.table-panel{margin-bottom:12px}.section-title{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}.section-title span{font-size:13px;color:var(--muted);font-weight:800}.table-actions{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px;padding:8px 10px;background:var(--soft);border:1px solid var(--line2);border-radius:7px}.table-actions label{display:inline-flex;align-items:center;gap:7px;font-weight:800;color:#4b5563}.table-actions input{width:auto}.data-table{width:100%;border-collapse:collapse;table-layout:fixed;background:#fff}.data-table th,.data-table td{border-bottom:1px solid var(--line2);padding:10px 8px;text-align:left;vertical-align:top;font-size:14px}.data-table th{background:#f8fafc;color:#4b5563;font-size:12px;font-weight:900}.data-table tr:hover td{background:#fcfdff}.w-check{width:38px}.w-no{width:58px}.w-id{width:72px}.w-status{width:86px}.w-account{width:138px}.w-date{width:142px}.w-action{width:112px}.url-cell a,.url-cell small,.text-cell strong,.text-cell small,.account-cell small{display:block;max-width:100%;overflow-wrap:anywhere;word-break:break-word;line-height:1.38}.url-cell small,.text-cell small,.account-cell small,.date-cell,.muted{color:var(--muted);font-size:12px;margin-top:4px}.note{color:#92400e!important}.score{display:inline-flex;align-items:center;justify-content:center;width:38px;height:28px;border-radius:7px;background:#111827;color:#fff;font-weight:900}.badge{display:inline-flex;align-items:center;min-height:24px;padding:4px 8px;border-radius:999px;background:#eef2f7;color:#374151;font-size:12px;font-weight:900}.join-success,.publish-available,.publish-success{background:#def7ec;color:var(--ok)}.join-failed,.publish-unavailable,.publish-failed,.badge.off{background:#fde8e8;color:var(--bad)}.join-pending,.join-running,.publish-pending,.publish-running{background:#fff4d6;color:#92400e}.publish-retryable_error{background:#e8f1ff;color:#1d4ed8}.action-cell{display:grid;gap:6px}.action-cell summary{list-style:none;display:flex;align-items:center;justify-content:center;min-height:31px;border:1px solid var(--line);border-radius:7px;color:var(--accent);font-size:13px;font-weight:900;cursor:pointer}.edit-form{display:grid;gap:6px;width:min(320px,72vw);margin-top:7px}.edit-form input{padding:8px;font-size:13px}.edit-form button,.danger-button{min-height:31px;padding:6px 9px;font-size:13px}.danger-button{width:100%;background:#fff;border-color:#f0b4b4;color:var(--bad)}.empty-state{text-align:center;color:var(--muted);padding:22px 12px!important;background:#fbfcfe}@media(max-width:1100px){.hide-lg{display:none}.metric-row{grid-template-columns:repeat(3,minmax(0,1fr))}.control-panel{grid-template-columns:1fr}.collect-form{grid-template-columns:1fr 1fr}.collect-form button{grid-column:1/-1}.w-action{width:96px}}@media(max-width:820px){.hide-md{display:none}.w-status{width:78px}.w-date{width:124px}.site-table .url-cell{width:auto}.metric-row{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:620px){.topbar{align-items:flex-start;padding:10px 14px}.page{padding:18px 10px 44px}.page-head h1{font-size:25px}.metric{display:block}.metric span{display:block;margin-top:4px}.control-block,.table-panel{padding:12px}.collect-form,.quick-add-form,.bulk-form{grid-template-columns:1fr}.hide-sm{display:none}.w-no{width:42px}.w-id{width:58px}.w-status{width:70px}.w-check{width:32px}.w-action{width:82px}.data-table th,.data-table td{padding:8px 5px;font-size:13px}.badge{font-size:11px;padding:3px 6px}.action-cell summary,.danger-button{font-size:12px;padding:5px 6px}}
.site-queue-form { margin:0; }
.site-check { width:auto; }
.inline-result { margin:0 0 10px; padding:10px 12px; border-radius:7px; font-weight:800; font-size:14px; }
.inline-result.ok { background:#def7ec; color:#046c4e; border:1px solid #a7f3d0; }
.inline-result.error { background:#fde8e8; color:#b42318; border:1px solid #fecaca; }
.join-running { background:#fff4d6; color:#92400e; }
.join-cancelled { background:#eef2f7; color:#4b5563; }
.post-panel { min-width:0; background:#fff; border:1px solid var(--line); border-radius:8px; padding:14px; margin-bottom:12px; }
.post-setting-form { display:grid; grid-template-columns:minmax(180px,.35fr) minmax(0,1fr) auto; gap:8px; align-items:start; }
.keyword-combo-grid { display:grid; grid-template-columns:repeat(5,minmax(120px,1fr)); gap:8px; grid-column:1 / -1; }
.js-post-save-result { color:var(--muted); font-weight:800; }
.multi-actions { align-items:center; }
.action-buttons { display:flex; gap:8px; flex-wrap:wrap; justify-content:flex-end; }
.publish-success { background:#def7ec; color:var(--ok); }
.publish-failed { background:#fde8e8; color:var(--bad); }
@media(max-width:900px){.post-setting-form{grid-template-columns:1fr}.keyword-combo-grid{grid-template-columns:1fr}.action-buttons{justify-content:stretch}.action-buttons button{flex:1}}

.post-setting-form{display:grid!important;grid-template-columns:1fr!important;gap:12px!important;}
.template-grid{display:grid;grid-template-columns:minmax(220px,.42fr) minmax(0,1fr);gap:10px;}
.template-grid label,.keyword-combo-grid label{display:grid;gap:6px;font-size:13px;font-weight:900;color:#4b5563;}
.keyword-combo-grid{display:grid!important;grid-template-columns:repeat(5,minmax(180px,1fr))!important;gap:10px!important;grid-column:auto!important;}
.keyword-combo-grid textarea{min-height:116px;line-height:1.5;}
.token-help{margin:0;color:var(--muted);font-size:13px;font-weight:800;}
@media(max-width:1100px){.keyword-combo-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.template-grid{grid-template-columns:1fr}}
@media(max-width:620px){.keyword-combo-grid{grid-template-columns:1fr!important}}

.history-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:10px}.history-tabs .badge.active{outline:2px solid var(--accent);outline-offset:2px}.history-table .text-cell{overflow-wrap:anywhere}.history-table .url-cell{overflow-wrap:anywhere}

.history-metric{border-color:#b9cdf8;background:#f5f8ff}.history-metric span{color:#1d4ed8}@media(min-width:1101px){.metric-row{grid-template-columns:repeat(6,minmax(0,1fr))}}
.cap-balance-status{display:inline-flex;align-items:center;min-height:28px;padding:4px 8px;border-radius:999px;background:#eef6ff;color:#1d4ed8;font-size:12px;font-weight:900;white-space:nowrap}.cap-balance-status:empty{display:none}.cap-balance-status.error{background:#fde8e8;color:#b42318}.cap-balance-status.ok{background:#def7ec;color:#047857}

.global-metric-row{position:sticky;top:58px;z-index:9;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px;padding:10px 16px;background:rgba(245,246,248,.96);backdrop-filter:blur(8px);border-bottom:1px solid var(--line);}
.global-metric-row .metric{margin:0;min-height:54px;}
@media(max-width:1100px){.global-metric-row{top:58px;grid-template-columns:repeat(3,minmax(0,1fr));}}
@media(max-width:620px){.global-metric-row{position:static;grid-template-columns:repeat(2,minmax(0,1fr));padding:8px 10px}.global-metric-row .metric{min-height:48px}}


/* Polished publish content editor */
.post-panel{
  padding:18px!important;
  border-color:#dbe3ef!important;
  box-shadow:0 10px 26px rgba(15,23,42,.05);
}

.telegram-contact-nav {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  min-height:36px;
  padding:8px 12px;
  border:1px solid rgba(15,118,110,.28);
  border-radius:8px;
  background:#ecfdf5;
  color:#047857!important;
  font-weight:950!important;
}
.telegram-contact-nav:hover {
  background:#d1fae5;
  color:#065f46!important;
  text-decoration:none;
}
.telegram-contact-button {
  border-color:#0f766e!important;
  background:#0f766e!important;
  color:#fff!important;
  box-shadow:0 12px 26px rgba(15,118,110,.18);
}
.telegram-contact-button:hover {
  background:#0b5f59!important;
  border-color:#0b5f59!important;
  text-decoration:none;
}
.telegram-contact-button b {
  font-weight:950;
}
.telegram-contact-mobile {
  background:#0f766e!important;
  color:#fff!important;
  border-color:#0f766e!important;
}

/* Access log dashboard v2 */
.access-filter-panel {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.access-tabs {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.access-tab {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  min-height: 48px;
  padding: 9px 11px;
  border: 1px solid #e3eaf3;
  border-radius: 12px;
  background: #f8fafc;
  color: #334155;
  text-decoration: none !important;
  font-weight: 950;
}

.access-tab span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.access-tab strong {
  color: #0f172a;
  font-size: 14px;
}

.access-tab.active {
  border-color: #1d4ed8;
  background: #eff6ff;
  color: #1d4ed8;
  box-shadow: 0 0 0 2px rgba(29, 78, 216, .08);
}

.access-filter-form {
  display: grid;
  grid-template-columns: 170px minmax(220px, 1fr) auto auto;
  gap: 8px;
  align-items: end;
}

.access-filter-form label {
  display: grid;
  gap: 5px;
  color: #475569;
  font-size: 12px;
  font-weight: 950;
}

.access-session-table {
  table-layout: auto;
}

.access-session-table th {
  white-space: nowrap;
}

.access-session-table td {
  font-size: 13px;
}

.access-session-table small,
.access-time-cell small {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 11px;
  font-weight: 850;
}

.access-badge.member {
  background: #e0f2fe;
  color: #0369a1;
}

.access-risk {
  display: inline-block !important;
  margin-top: 6px;
  color: #b42318 !important;
  font-weight: 950 !important;
}

.access-detail summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid #dbe4f0;
  border-radius: 999px;
  background: #fff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 950;
  cursor: pointer;
  list-style: none;
}

.access-detail summary::-webkit-details-marker {
  display: none;
}

.access-detail-box {
  width: min(560px, 78vw);
  margin-top: 8px;
  padding: 12px;
  border: 1px solid #e3eaf3;
  border-radius: 12px;
  background: #f8fafc;
  color: #334155;
  line-height: 1.5;
}

.access-detail-box p {
  margin: 0 0 8px;
}

.access-detail-box p strong {
  display: block;
  margin-bottom: 4px;
  color: #0f172a;
  font-size: 12px;
}

.access-detail-box p span,
.access-detail-box li {
  overflow-wrap: anywhere;
  word-break: break-word;
  font-size: 12px;
}

.access-detail-box ul {
  display: grid;
  gap: 5px;
  max-height: 220px;
  overflow: auto;
  margin: 4px 0 10px;
  padding-left: 18px;
}

.access-bottom-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 12px;
}

@media (max-width: 1100px) {
  .access-tabs {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .access-filter-form {
    grid-template-columns: 150px minmax(180px, 1fr) auto auto;
  }

  .access-bottom-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .access-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .access-filter-form {
    grid-template-columns: 1fr;
  }

  .access-filter-form .button {
    width: 100%;
  }

.access-detail-box {
    width: 100%;
  }
}

/* Point admin user filter */
.point-admin-filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 14px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #dbe4f0;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.point-user-filter-form {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto auto;
  gap: 8px;
  align-items: end;
}

.point-user-filter-form label {
  display: grid;
  gap: 6px;
  color: #475569;
  font-size: 12px;
  font-weight: 950;
}

.point-user-filter-form select {
  min-height: 40px;
}

.point-selected-user {
  min-width: 220px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #edf1f6;
}

.point-selected-user strong {
  display: block;
  color: #0f172a;
  font-size: 15px;
  font-weight: 950;
}

.point-selected-user span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.45;
}

@media (max-width: 860px) {
  .point-admin-filter-panel,
  .point-user-filter-form {
    grid-template-columns: 1fr;
  }

  .point-user-filter-form .button {
    width: 100%;
  }
}

/* Admin access logs */
.access-page-head {
  align-items: center;
  margin-bottom: 16px;
}

.page-subtitle {
  margin: 7px 0 0;
  color: #64748b;
  font-size: 14px;
  font-weight: 750;
}

.access-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.access-kpi-grid article {
  min-width: 0;
  padding: 18px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: linear-gradient(180deg, #fff, #f8fbff);
  box-shadow: 0 10px 24px rgba(15, 23, 42, .05);
}

.access-kpi-grid span {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 950;
}

.access-kpi-grid strong {
  display: block;
  margin-top: 8px;
  color: #0f172a;
  font-size: 30px;
  line-height: 1;
  letter-spacing: 0;
}

.access-kpi-grid small {
  display: block;
  margin-top: 9px;
  color: #475569;
  font-size: 12px;
  font-weight: 850;
}

.access-insight-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.access-insight-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.section-title.compact {
  align-items: flex-start;
  margin-bottom: 12px;
}

.section-title.compact h2 {
  font-size: 17px;
}

.access-rank-list {
  display: grid;
  gap: 8px;
}

.access-rank-list div {
  min-width: 0;
  padding: 10px 11px;
  border: 1px solid #edf1f6;
  border-radius: 10px;
  background: #f8fafc;
}

.access-rank-list strong {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #0f172a;
  font-size: 13px;
  font-weight: 950;
}

.access-rank-list span {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}

.empty-mini {
  margin: 0;
  padding: 18px 10px;
  color: #64748b;
  text-align: center;
  font-size: 13px;
  font-weight: 850;
}

.access-panel {
  border-radius: 12px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.access-daily-table th,
.access-log-table th,
.login-log-table th {
  white-space: nowrap;
}

.access-daily-table td {
  font-weight: 850;
}

.access-log-table,
.login-log-table {
  table-layout: auto;
}

.access-log-table td,
.login-log-table td {
  font-size: 13px;
}

.access-time-cell {
  min-width: 138px;
  color: #475569;
  font-weight: 850;
  white-space: nowrap;
}

.access-url-cell {
  max-width: 320px;
}

.access-url-cell strong {
  display: inline-flex;
  min-width: 44px;
  min-height: 22px;
  align-items: center;
  justify-content: center;
  margin-right: 6px;
  border-radius: 999px;
  background: #eef2ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 950;
}

.access-url-cell span,
.access-url-cell small,
.access-ua-cell {
  display: inline-block;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
  color: #475569;
  line-height: 1.45;
}

.access-ua-cell {
  max-width: 420px;
  font-size: 12px !important;
}

.access-badge {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 950;
  white-space: nowrap;
}

.access-badge.user,
.access-badge.success {
  background: #dcfce7;
  color: #047857;
}

.access-badge.bot {
  background: #fee2e2;
  color: #b42318;
}

.access-badge.fail {
  background: #fff4d6;
  color: #92400e;
}

@media (max-width: 1100px) {
  .access-kpi-grid,
  .access-insight-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .access-insight-grid .access-insight-card:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .access-page-head {
    align-items: stretch;
    display: grid;
  }

  .access-page-head .head-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .access-kpi-grid,
  .access-insight-grid {
    grid-template-columns: 1fr;
  }

  .access-kpi-grid article,
  .access-insight-card,
  .access-panel {
    border-radius: 14px;
  }

  .access-kpi-grid strong {
    font-size: 28px;
  }

  .access-url-cell,
  .access-ua-cell {
    max-width: 100%;
  }
}

/* Billing and pricing */
.billing-head p {
  margin: 8px 0 0;
  color: #526076;
  font-weight: 600;
}

.billing-notice-panel,
.wallet-guide-panel,
.public-pricing-panel {
  margin-bottom: 22px;
  border: 1px solid #dce6f3;
  border-radius: 18px;
  background: linear-gradient(135deg, #ffffff 0%, #f5fbff 100%);
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.07);
}

.billing-notice-panel,
.wallet-guide-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 22px;
}

.billing-notice-panel strong,
.wallet-guide-panel h2 {
  color: #0f172a;
  font-size: 22px;
}

.billing-notice-panel p,
.wallet-guide-panel p {
  margin: 8px 0 0;
  color: #526076;
}

.billing-notice-panel ul {
  display: grid;
  gap: 8px;
  min-width: 240px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.billing-notice-panel li {
  padding: 9px 12px;
  border-radius: 999px;
  background: #eef6ff;
  color: #153452;
  font-weight: 700;
}

.billing-plan-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.billing-plan-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 100%;
  padding: 22px;
  border: 1px solid #dce6f3;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.07);
}

.billing-plan-card.featured {
  border-color: #1d4ed8;
  box-shadow: 0 22px 55px rgba(29, 78, 216, 0.18);
}

.plan-badge-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.plan-badge,
.recommend-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.plan-badge {
  background: #eef2ff;
  color: #1e3a8a;
}

.recommend-badge {
  background: #0f172a;
  color: #fff;
}

.billing-plan-card h2,
.billing-plan-card h3 {
  margin: 0;
  font-size: 28px;
  color: #0f172a;
}

.billing-plan-card p {
  margin: 0;
  min-height: 42px;
  color: #526076;
  line-height: 1.55;
}

.plan-price {
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 12px 0;
  border-top: 1px solid #edf2f7;
  border-bottom: 1px solid #edf2f7;
}

.plan-price strong {
  font-size: 38px;
  line-height: 1;
  color: #0f172a;
}

.plan-price span {
  color: #526076;
  font-weight: 800;
}

.plan-specs {
  display: grid;
  gap: 8px;
  margin: 0;
}

.plan-specs div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
}

.plan-specs dt {
  color: #64748b;
  font-weight: 700;
}

.plan-specs dd {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  text-align: right;
}

.plan-features {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: #334155;
  font-size: 14px;
}

.plan-features li::before {
  content: "✓";
  margin-right: 6px;
  color: #16a34a;
  font-weight: 900;
}

.billing-plan-card form,
.billing-plan-card .button {
  margin-top: auto;
}

.billing-plan-card .button {
  width: 100%;
  justify-content: center;
}

.wallet-guide-panel {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr) minmax(0, 1.2fr);
}

.wallet-box {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid #dce6f3;
  border-radius: 14px;
  background: #fff;
}

.wallet-box span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.wallet-box code,
.wallet-cell code {
  display: block;
  max-width: 100%;
  overflow-wrap: anywhere;
  white-space: normal;
  color: #0f172a;
  font-weight: 800;
}

.billing-orders-panel {
  margin-top: 12px;
}

.billing-pay-amount strong {
  display: block;
  color: #0f172a;
  font-size: 16px;
}

.billing-pay-amount small,
.billing-actions-cell small,
.date-cell small {
  display: block;
  margin-top: 3px;
  color: #64748b;
}

.billing-actions-cell {
  display: grid;
  gap: 8px;
}

.admin-payment-approve-form {
  display: grid;
  gap: 6px;
}

.admin-payment-approve-form input {
  min-width: 160px;
  height: 34px;
  border: 1px solid #d7e0eb;
  border-radius: 9px;
  padding: 0 10px;
}

.badge.payment-pending {
  background: #fff7ed;
  color: #c2410c;
}

.badge.payment-paid {
  background: #dcfce7;
  color: #166534;
}

.badge.payment-expired,
.badge.payment-cancelled {
  background: #fee2e2;
  color: #991b1b;
}

.public-pricing-panel {
  padding: 26px;
}

.public-price-grid {
  margin-bottom: 10px;
}

.pricing-note {
  margin: 14px 0 0;
  color: #64748b;
  font-size: 14px;
}

.mono-text {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  overflow-wrap: anywhere;
}

@media (max-width: 1180px) {
  .billing-plan-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wallet-guide-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .billing-notice-panel,
  .wallet-guide-panel {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .billing-plan-grid {
    grid-template-columns: 1fr;
  }

  .billing-plan-card {
    padding: 19px;
  }

  .billing-plan-card p {
    min-height: 0;
  }

  .plan-price strong {
    font-size: 34px;
  }

  .plan-specs div {
    align-items: flex-start;
  }

  .public-pricing-panel {
    padding: 18px;
  }
}

/* Admin user post settings modal */
body.modal-open {
  overflow: hidden;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(8, 15, 30, 0.58);
  backdrop-filter: blur(6px);
}

.modal-backdrop[hidden] {
  display: none !important;
}

.modal-card {
  width: min(720px, 100%);
  max-height: min(780px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 28px 90px rgba(15, 23, 42, 0.34);
}

.large-modal {
  width: min(980px, 100%);
}

.modal-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 24px 16px;
  border-bottom: 1px solid #e5eaf2;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
}

.modal-head h2 {
  margin: 4px 0 0;
  font-size: 22px;
  line-height: 1.25;
  color: #0f172a;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid #d8e0ec;
  border-radius: 999px;
  background: #f8fafc;
  color: #0f172a;
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.icon-button:hover {
  background: #eef4ff;
}

.post-settings-preview-list {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #f7f9fc;
}

.post-settings-preview-card {
  border: 1px solid #dfe7f2;
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}

.preview-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid #edf1f7;
  background: #fbfdff;
}

.post-settings-preview-grid {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  margin: 0;
}

.post-settings-preview-grid dt,
.post-settings-preview-grid dd {
  margin: 0;
  padding: 12px 16px;
  border-bottom: 1px solid #eef2f7;
}

.post-settings-preview-grid dt {
  font-weight: 800;
  color: #526076;
  background: #f8fafc;
}

.post-settings-preview-grid dd {
  min-width: 0;
  color: #111827;
  overflow-wrap: anywhere;
}

.post-settings-preview-grid dt:last-of-type,
.post-settings-preview-grid dd:last-of-type {
  border-bottom: 0;
}

.pre-line {
  white-space: pre-wrap;
}

.modal-empty {
  margin: 18px;
}

@media (max-width: 720px) {
  .modal-backdrop {
    align-items: flex-end;
    padding: 12px;
  }

  .modal-card {
    max-height: calc(100vh - 24px);
    border-radius: 18px 18px 12px 12px;
  }

  .modal-head {
    padding: 18px 16px 13px;
  }

  .modal-head h2 {
    font-size: 18px;
  }

  .post-settings-preview-list {
    padding: 12px;
  }

  .post-settings-preview-grid {
    grid-template-columns: 1fr;
  }

  .post-settings-preview-grid dt {
    padding: 11px 14px 4px;
    border-bottom: 0;
    background: #fff;
  }

  .post-settings-preview-grid dd {
    padding: 0 14px 12px;
  }
}
.post-panel .section-title{
  margin-bottom:14px;
  padding-bottom:12px;
  border-bottom:1px solid var(--line2);
}
.post-panel .section-title h2{
  font-size:19px;
  letter-spacing:0;
}
.post-panel .js-post-save-result{
  min-height:24px;
  padding:3px 0;
  font-size:13px;
}
.post-setting-form{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:14px!important;
  align-items:stretch!important;
}
.template-grid{
  display:grid!important;
  grid-template-columns:minmax(260px,.62fr) minmax(0,1.38fr)!important;
  gap:12px!important;
  align-items:stretch;
}
.template-grid label,
.keyword-combo-grid label{
  min-width:0;
  display:grid!important;
  gap:8px!important;
  align-content:start;
  padding:12px;
  border:1px solid var(--line2);
  border-radius:8px;
  background:#fbfcfe;
  color:#334155!important;
  font-size:13px!important;
  font-weight:900!important;
}
.template-grid input,
.template-grid textarea,
.keyword-combo-grid textarea{
  border-color:#d8e0ea;
  background:#fff;
  border-radius:7px;
  box-shadow:inset 0 1px 0 rgba(15,23,42,.02);
}
.template-grid input{
  min-height:44px;
}
.template-grid textarea{
  min-height:132px;
}
.keyword-combo-grid{
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:12px!important;
  align-items:stretch;
}
.keyword-combo-grid label{
  min-height:218px;
}
.keyword-combo-grid textarea{
  min-height:162px!important;
  height:100%;
  resize:vertical;
  line-height:1.55;
}
.token-help{
  margin:0!important;
  padding:10px 12px;
  border:1px solid #dbeafe;
  border-radius:8px;
  background:#eff6ff;
  color:#1e3a8a!important;
  font-size:13px!important;
  font-weight:800!important;
}
.post-setting-form .js-post-save-button{
  justify-self:end;
  min-width:132px;
  min-height:40px;
}
@media(max-width:1180px){
  .keyword-combo-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
@media(max-width:820px){
  .template-grid{grid-template-columns:1fr!important;}
  .keyword-combo-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}
@media(max-width:560px){
  .post-panel{padding:14px!important;}
  .keyword-combo-grid{grid-template-columns:1fr!important;}
  .post-setting-form .js-post-save-button{justify-self:stretch;}
}

@media(min-width:1101px){.global-metric-row{grid-template-columns:repeat(7,minmax(0,1fr))}}


/* UX reorder: wide candidate collector and direct add below publisher */
.control-panel{
  grid-template-columns:1fr!important;
  gap:12px!important;
}
.control-panel .control-block{
  padding:18px!important;
  border-color:#dbe3ef!important;
  box-shadow:0 10px 26px rgba(15,23,42,.05);
}
.control-panel .control-block h2{
  margin-bottom:12px!important;
  font-size:19px!important;
}
.collect-form{
  display:grid!important;
  grid-template-columns:minmax(320px,1fr) 150px 110px 120px 96px!important;
  gap:10px!important;
  align-items:end!important;
}
.collect-form input[name="keyword"]{
  min-width:0;
}
.direct-site-panel{
  min-width:0;
  margin-bottom:12px;
  padding:16px 18px;
  border:1px solid #dbe3ef;
  border-radius:8px;
  background:#fff;
  box-shadow:0 10px 26px rgba(15,23,42,.05);
}
.direct-site-panel h2{
  margin:0 0 12px;
  font-size:18px;
  letter-spacing:0;
  color:#0f172a;
}
.direct-add-form{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) 96px!important;
  gap:10px!important;
  align-items:end!important;
}
.direct-add-form input{
  min-width:0;
}
@media(max-width:900px){
  .collect-form,
  .direct-add-form{
    grid-template-columns:1fr!important;
  }
  .direct-add-form .button,
  .collect-form .button{
    width:100%;
  }
}


/* Collect form labeled UX */
.collect-form{
  grid-template-columns:minmax(220px,420px) 150px 110px 120px 96px!important;
  justify-content:start!important;
  align-items:end!important;
}
.collect-field{
  min-width:0;
  display:grid;
  gap:6px;
  color:#475569;
  font-size:12px;
  font-weight:800;
  letter-spacing:0;
}
.collect-field span{
  line-height:1;
}
.collect-field input,
.collect-field select{
  width:100%;
}
.collect-keyword-field input{
  max-width:420px;
}
.collect-small-field input{
  text-align:center;
}
@media(max-width:900px){
  .collect-form{
    grid-template-columns:1fr 1fr!important;
  }
  .collect-keyword-field,
  .collect-form .js-collect-button{
    grid-column:1 / -1;
  }
  .collect-keyword-field input{
    max-width:none;
  }
}
@media(max-width:560px){
  .collect-form{
    grid-template-columns:1fr!important;
  }
}


/* Publish repeat field */
.publish-repeat-field{
  display:inline-grid!important;
  grid-template-columns:auto 76px;
  align-items:center;
  gap:6px;
  min-height:38px;
  padding:0 8px;
  border:1px solid var(--line2);
  border-radius:7px;
  background:#fff;
  color:#475569;
  font-size:12px;
  font-weight:900;
}
.publish-repeat-field input{
  width:76px!important;
  height:30px!important;
  min-height:30px!important;
  padding:4px 8px!important;
  text-align:center;
}
@media(max-width:900px){
  .publish-repeat-field{
    flex:1 1 100%;
    grid-template-columns:auto minmax(84px,1fr);
  }
  .publish-repeat-field input{width:100%!important;}
}


/* Collect running lock */
.collect-form [disabled]{
  opacity:.62;
  cursor:not-allowed;
}
.collect-running-note{
  margin-top:10px;
}


/* Publish cancel */
.button.danger{background:#b91c1c;color:#fff;border-color:#b91c1c;}
.button.danger:hover{background:#991b1b;border-color:#991b1b;}
.publish-cancelled{background:#eef2f7;color:#4b5563;}


/* Split dashboard UX */
.dashboard-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin-bottom:14px}.dash-card{min-width:0;padding:16px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--text);box-shadow:0 8px 18px rgba(15,23,42,.04)}.dash-card span{display:block;color:var(--muted);font-size:13px;font-weight:900}.dash-card strong{display:block;margin-top:8px;font-size:30px}.dash-card.ok strong{color:var(--ok)}.dash-card.bad strong{color:var(--bad)}.dash-card.warn strong{color:#92400e}.quick-menu-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:14px}.quick-menu-card{display:grid;gap:7px;min-width:0;padding:16px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--text)}.quick-menu-card strong{font-size:17px}.quick-menu-card span{color:var(--muted);font-size:13px;line-height:1.45}.filter-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:12px}.filter-tabs .badge.active{outline:2px solid var(--accent);outline-offset:2px}.pager{display:flex;align-items:center;justify-content:center;gap:12px;padding:14px 0 2px}.pager span{font-weight:900;color:var(--muted)}.compact-table th:first-child,.compact-table td:first-child{width:78px}.light-panel{box-shadow:0 8px 18px rgba(15,23,42,.04)}.topbar nav a{font-weight:800;color:#334155}.topbar nav a:hover{color:var(--accent)}@media(max-width:1100px){.dashboard-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.quick-menu-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:620px){.dashboard-grid,.quick-menu-grid{grid-template-columns:1fr}.dash-card{padding:14px}.dash-card strong{font-size:26px}.filter-tabs .badge{flex:1;justify-content:center}}


/* Main dashboard action cards */
.dashboard-head{margin-bottom:12px;}
.home-action-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:14px;}
.home-action-card{position:relative;display:grid;gap:8px;min-height:128px;padding:18px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--text);box-shadow:0 10px 24px rgba(15,23,42,.06);transition:transform .15s ease,border-color .15s ease,box-shadow .15s ease;}
.home-action-card:hover{transform:translateY(-2px);border-color:var(--accent);box-shadow:0 16px 34px rgba(15,23,42,.1);}
.home-action-card strong{font-size:22px;line-height:1.15;letter-spacing:0;}
.home-action-card small{color:var(--muted);font-size:14px;line-height:1.45;font-weight:800;}
.home-action-card .action-kicker{width:28px;height:28px;display:inline-grid;place-items:center;border-radius:999px;background:#eef6ff;color:var(--accent);font-weight:900;font-size:13px;}
.home-action-card.primary-action{background:#0f172a;color:#fff;border-color:#0f172a;}
.home-action-card.primary-action small{color:#dbeafe;}
.home-action-card.primary-action .action-kicker{background:#fff;color:#0f172a;}
@media(max-width:1100px){.home-action-grid{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:620px){.home-action-grid{grid-template-columns:1fr}.home-action-card{min-height:108px}.home-action-card strong{font-size:20px;}}


/* Top navigation quick access */
.topbar{align-items:center;}
.main-nav{display:flex;align-items:center;gap:8px;flex-wrap:wrap;justify-content:flex-end;}
.main-nav a{display:inline-flex;align-items:center;min-height:34px;padding:7px 10px;border-radius:7px;color:#334155;font-size:14px;font-weight:900;white-space:nowrap;}
.main-nav a:hover{background:#eef6ff;color:var(--accent);text-decoration:none;}
.main-nav a.active{background:#0f172a;color:#fff;}
.main-nav form{margin:0;}
.main-nav button{min-height:34px;padding:7px 10px;font-size:13px;}
@media(max-width:900px){
  .topbar{align-items:flex-start;flex-direction:column;gap:8px;padding:10px 14px;}
  .main-nav{width:100%;justify-content:flex-start;gap:6px;}
  .main-nav a{flex:1 1 auto;justify-content:center;font-size:13px;padding:7px 8px;}
  .main-nav form{flex:1 1 100%;}
  .main-nav button{width:100%;}
  .global-metric-row{top:118px;}
}
@media(max-width:620px){
  .main-nav{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));}
  .main-nav a,.main-nav form{min-width:0;}
  .main-nav a{white-space:normal;text-align:center;}
}


/* Admin site import */
.import-admin-panel{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:12px;padding:18px;border:1px solid #dbe3ef;border-radius:8px;background:#fff;box-shadow:0 10px 26px rgba(15,23,42,.05)}
.import-admin-panel h2{margin:0 0 6px;font-size:19px;color:#0f172a;letter-spacing:0}
.import-admin-panel p{margin:0;color:#475569;font-size:14px;font-weight:800;line-height:1.45}
.import-admin-panel small{display:block;margin-top:6px;color:#64748b;font-size:12px;font-weight:900}
.import-admin-panel form{margin:0;flex:0 0 auto}
@media(max-width:720px){.import-admin-panel{align-items:stretch;flex-direction:column}.import-admin-panel .button{width:100%}}

/* Telegram verification */
.point-balance{font-size:36px;font-weight:900;margin:8px 0 14px;color:#0f172a;}
.admin-publish-cell{display:grid;gap:7px}
.admin-publish-cell>strong{font-size:18px;color:#0f172a}
.admin-publish-controls{display:grid;grid-template-columns:repeat(2,minmax(128px,1fr));gap:8px}
.admin-publish-controls label{display:grid;gap:4px;font-size:12px;font-weight:900;color:#64748b}
.admin-publish-controls input{width:100%;min-width:96px;min-height:40px;padding:8px 12px;text-align:center;font-size:16px;font-weight:950}
.admin-setting-panel{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 12px;padding:14px;border:1px solid var(--line);border-radius:10px;background:#f8fafc}
.admin-setting-panel>div{display:grid;gap:5px}
.admin-setting-panel strong{font-size:16px;color:#0f172a}
.admin-setting-panel small{color:#64748b;font-size:12px;font-weight:800}
.button.danger,button.danger{background:#b42318;border-color:#b42318;color:#fff}
.verify-code-box{display:inline-flex;align-items:center;min-height:46px;padding:0 18px;border:1px solid var(--line);border-radius:8px;background:#f8fafc;font-size:22px;font-weight:900;letter-spacing:1px;margin:10px 0 14px;}
.code-guide{max-width:360px;padding:12px 14px;border-radius:8px;background:#111827;color:#f9fafb;overflow-x:auto;}


/* point history */
.metric-grid.compact{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-bottom:14px}.panel{min-width:0;background:#fff;border:1px solid var(--line);border-radius:8px;padding:14px;margin-bottom:14px}.toolbar{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}.segmented{display:flex;gap:8px;flex-wrap:wrap}.segmented a{display:inline-flex;align-items:center;min-height:32px;padding:6px 10px;border:1px solid var(--line);border-radius:999px;background:#fff;color:var(--text);font-size:13px;font-weight:900}.segmented a.active{border-color:var(--accent);background:#e8f1ff;color:var(--accent)}.table-wrap{width:100%;overflow-x:auto}.badge.success{background:#def7ec;color:var(--ok)}.badge.danger{background:#fde8e8;color:var(--bad)}.text-success{color:var(--ok);font-weight:900}.text-danger{color:var(--bad);font-weight:900}.data-table small{display:block;color:var(--muted);font-size:11px;margin-top:4px;overflow-wrap:anywhere}.empty{text-align:center;color:var(--muted);padding:24px 12px!important}.pagination{display:flex;align-items:center;justify-content:center;gap:12px;padding:14px 0 2px}.pagination span{font-weight:900;color:var(--muted)}.head-actions{display:flex;gap:8px;flex-wrap:wrap}@media(max-width:820px){.metric-grid.compact{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:620px){.metric-grid.compact{grid-template-columns:1fr}.toolbar{align-items:stretch}.segmented a{flex:1;justify-content:center}}


/* brand logo */
.brand{display:inline-flex;align-items:center;gap:9px;min-height:40px;font-size:20px;font-weight:900;color:var(--text);letter-spacing:0;text-decoration:none}.brand:hover{text-decoration:none;color:var(--text)}.brand-logo{width:34px;height:34px;display:block;flex:0 0 auto;border-radius:9px}.brand-text{display:inline-block;white-space:nowrap;line-height:1}@media(max-width:620px){.brand{font-size:19px}.brand-logo{width:32px;height:32px}}


/* public home */
.home-hero{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(360px,.95fr);gap:28px;align-items:center;min-height:520px;padding:34px 0 42px}.home-hero-copy h1{max-width:760px;margin:8px 0 14px;font-size:48px;line-height:1.12;letter-spacing:0;color:#0f172a}.home-lead{max-width:720px;margin:0;color:#475569;font-size:18px;line-height:1.75}.home-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:26px}.home-preview{min-width:0;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 18px 42px rgba(15,23,42,.10);overflow:hidden}.preview-top{display:flex;align-items:center;gap:8px;padding:14px 16px;border-bottom:1px solid var(--line2);background:#f8fafc}.preview-top span{width:10px;height:10px;border-radius:50%;background:#cbd5e1}.preview-top span:nth-child(1){background:#ef4444}.preview-top span:nth-child(2){background:#f59e0b}.preview-top span:nth-child(3){background:#10b981}.preview-top strong{margin-left:auto;color:#0f172a}.preview-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:16px}.preview-stats div{padding:14px;border:1px solid var(--line2);border-radius:8px;background:#fff}.preview-stats strong{display:block;color:#0f172a;font-size:22px}.preview-stats span{display:block;margin-top:4px;color:var(--muted);font-size:12px;font-weight:800}.preview-table{padding:0 16px 16px}.preview-table>div{display:grid;grid-template-columns:minmax(0,1fr) 96px 70px;gap:8px;align-items:center;padding:10px 0;border-bottom:1px solid var(--line2);font-size:13px}.preview-table b{color:#64748b;font-size:12px}.preview-table span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.preview-table em{font-style:normal;font-weight:900;font-size:12px}.preview-table .ok{color:var(--ok)}.preview-table .warn{color:#92400e}.preview-table .bad{color:var(--bad)}.home-section{margin:18px 0 22px}.home-section h2{margin:4px 0 12px;font-size:28px;letter-spacing:0;color:#0f172a}.feature-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.feature-grid article{min-width:0;padding:18px;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 8px 18px rgba(15,23,42,.04)}.feature-grid strong{display:block;color:#0f172a;font-size:16px}.feature-grid p{margin:8px 0 0;color:#64748b;font-size:14px;line-height:1.62}.seo-copy{padding:22px;border:1px solid var(--line);border-radius:8px;background:#fff}.seo-copy p:last-child{max-width:980px;margin:0;color:#475569;font-size:16px;line-height:1.8}@media(max-width:1040px){.home-hero{grid-template-columns:1fr;min-height:0}.home-preview{max-width:720px}.feature-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.home-hero-copy h1{font-size:40px}}@media(max-width:620px){.home-hero{padding:20px 0 26px;gap:18px}.home-hero-copy h1{font-size:32px}.home-lead{font-size:16px}.home-actions .button{flex:1 1 100%}.preview-stats{grid-template-columns:1fr}.preview-table>div{grid-template-columns:minmax(0,1fr) 82px 54px}.feature-grid{grid-template-columns:1fr}.home-section h2{font-size:24px}.seo-copy{padding:16px}}


/* official public landing */
.official-hero{display:grid;grid-template-columns:minmax(0,1.02fr) minmax(380px,.98fr);gap:36px;align-items:center;min-height:620px;padding:52px 0 42px}
.official-hero__copy h1{margin:8px 0 6px;color:#07111f;font-size:64px;line-height:1.04;letter-spacing:0;font-weight:950}
.official-subtitle{margin:0 0 16px;color:#1d4ed8;font-size:25px;font-weight:950}
.official-lead{max-width:760px;margin:0;color:#475569;font-size:18px;line-height:1.78}
.official-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:26px}
.official-proof{display:flex;gap:8px;flex-wrap:wrap;margin-top:22px}.official-proof span{display:inline-flex;align-items:center;min-height:30px;padding:6px 10px;border:1px solid #d9e3f0;border-radius:999px;background:#fff;color:#334155;font-size:13px;font-weight:900}
.official-console{min-width:0;border:1px solid #dbe4f0;border-radius:8px;background:#fff;box-shadow:0 24px 58px rgba(15,23,42,.14);overflow:hidden}.console-header{display:flex;align-items:center;gap:8px;padding:16px 18px;border-bottom:1px solid #edf1f6;background:#f8fafc}.console-header span{width:10px;height:10px;border-radius:50%;background:#cbd5e1}.console-header span:nth-child(1){background:#ef4444}.console-header span:nth-child(2){background:#f59e0b}.console-header span:nth-child(3){background:#10b981}.console-header strong{margin-left:auto;color:#0f172a;font-size:14px}
.console-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:18px}.console-metrics div{min-width:0;padding:16px;border:1px solid #edf1f6;border-radius:8px;background:linear-gradient(180deg,#fff,#fbfdff)}.console-metrics b{display:block;color:#64748b;font-size:12px}.console-metrics strong{display:block;margin-top:6px;color:#0f172a;font-size:19px}.console-list{padding:0 18px 18px}.console-list>div{display:grid;grid-template-columns:minmax(0,1fr) 92px 58px;gap:10px;align-items:center;padding:13px 0;border-bottom:1px solid #edf1f6;font-size:14px}.console-list span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#334155;font-weight:800}.console-list em{font-style:normal;font-size:12px;font-weight:950}.console-list strong{font-size:12px;color:#64748b}.console-list .ok{color:var(--ok)}.console-list .warn{color:#92400e}.console-list .bad{color:var(--bad)}
.official-section,.official-flow,.official-split,.official-contact{margin:22px 0}.official-section__head{display:grid;grid-template-columns:minmax(0,.9fr) minmax(300px,.7fr);gap:18px;align-items:end;margin-bottom:14px}.official-section__head h2,.official-flow h2,.official-split h2,.official-contact h2{margin:4px 0 0;color:#0f172a;font-size:31px;line-height:1.25;letter-spacing:0}.official-section__head p:last-child,.official-split p,.official-contact p{margin:0;color:#64748b;font-size:15px;line-height:1.75}
.official-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.official-card-grid article{min-width:0;padding:20px;border:1px solid #dfe7f1;border-radius:8px;background:#fff;box-shadow:0 8px 18px rgba(15,23,42,.04)}.official-card-grid strong{display:block;color:#0f172a;font-size:17px}.official-card-grid p{margin:9px 0 0;color:#64748b;font-size:14px;line-height:1.65}
.official-flow{display:grid;grid-template-columns:minmax(260px,.42fr) minmax(0,.58fr);gap:18px;padding:24px;border:1px solid #dfe7f1;border-radius:8px;background:#fff}.official-flow ol{display:grid;gap:10px;margin:0;padding:0;list-style:none}.official-flow li{display:grid;gap:4px;padding:14px;border:1px solid #edf1f6;border-radius:8px;background:#f8fafc}.official-flow strong{color:#0f172a}.official-flow span{color:#64748b;font-size:14px}
.official-split{display:grid;grid-template-columns:minmax(0,1fr) minmax(300px,.72fr);gap:18px;align-items:center;padding:24px;border-radius:8px;background:#0f172a;color:#fff}.official-split h2{color:#fff}.official-split p{color:#d7dee9}.official-keywords{display:flex;gap:9px;flex-wrap:wrap;justify-content:flex-end}.official-keywords span{display:inline-flex;align-items:center;min-height:34px;padding:8px 11px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:rgba(255,255,255,.08);color:#f8fafc;font-size:13px;font-weight:900}
.official-contact{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:24px;border:1px solid #dfe7f1;border-radius:8px;background:#fff}.official-contact .official-actions{margin-top:0}
@media(max-width:1080px){.official-hero{grid-template-columns:1fr;min-height:0}.official-console{max-width:760px}.official-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.official-section__head,.official-flow,.official-split{grid-template-columns:1fr}.official-keywords{justify-content:flex-start}.official-hero__copy h1{font-size:52px}}
@media(max-width:660px){.official-hero{padding:30px 0}.official-hero__copy h1{font-size:42px}.official-subtitle{font-size:20px}.official-lead{font-size:16px}.official-actions .button{flex:1 1 100%}.official-proof span{flex:1 1 auto;justify-content:center}.console-metrics{grid-template-columns:1fr}.console-list>div{grid-template-columns:minmax(0,1fr) 78px 48px}.official-card-grid{grid-template-columns:1fr}.official-section__head h2,.official-flow h2,.official-split h2,.official-contact h2{font-size:25px}.official-flow,.official-split,.official-contact{padding:18px}.official-contact{display:grid}}
.stack-form {
  display: grid;
  gap: 14px;
}

.stack-form label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

.stack-form input,
.stack-form select,
.stack-form textarea,
.admin-user-table input,
.admin-user-table select {
  width: 100%;
  border: 1px solid var(--line, #dbe3ef);
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
}

.message-list {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}

.message-item {
  border: 1px solid var(--line, #dbe3ef);
  border-radius: 10px;
  padding: 14px;
  background: #fff;
}

.message-item.is-admin {
  background: #f3f8ff;
}

.message-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  color: #4b5563;
  font-size: 13px;
}

.muted {
  display: block;
  color: #6b7280;
  font-size: 12px;
  margin-top: 4px;
  word-break: break-all;
}

.admin-user-table td {
  vertical-align: top;
}

.official-subpage-hero {
  min-height: 420px;
}

.official-subpage-hero .official-keywords {
  align-self: center;
}

/* Mobile dashboard and site-management polish */
@media (max-width: 760px) {
  body {
    background: #f6f8fb;
  }

  .topbar {
    position: static;
    padding: 10px 12px;
  }

  .main-nav {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 6px;
  }

  .main-nav a,
  .main-nav form,
  .main-nav button {
    width: 100%;
    min-width: 0;
  }

  .main-nav a,
  .main-nav button {
    min-height: 38px;
    justify-content: center;
    padding: 8px 6px;
    font-size: 12px;
    white-space: normal;
    text-align: center;
  }

  .page {
    padding: 14px 10px 44px;
  }

  .page-head {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 10px;
  }

  .page-head h1 {
    font-size: 24px;
  }

  .head-count {
    align-self: flex-start;
  }

  .global-metric-row {
    position: static !important;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    padding: 8px 10px;
  }

  .global-metric-row .metric {
    display: grid;
    gap: 2px;
    min-height: 58px;
    padding: 9px 10px;
  }

  .global-metric-row .metric strong {
    font-size: 19px;
    line-height: 1.1;
  }

  .global-metric-row .metric span {
    margin: 0;
    font-size: 12px;
  }

  .dashboard-grid,
  .quick-menu-grid,
  .home-action-grid,
  .metric-grid.compact {
    grid-template-columns: 1fr !important;
  }

  .dash-card,
  .quick-menu-card,
  .home-action-card,
  .panel,
  .table-panel,
  .control-block,
  .direct-site-panel,
  .fold-panel {
    border-radius: 10px;
    padding: 12px !important;
  }

  .filter-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .filter-tabs .badge {
    justify-content: center;
    min-height: 36px;
    text-align: center;
  }

  .table-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
  }

  .table-actions label {
    width: 100%;
    min-height: 36px;
  }

  .action-buttons {
    display: grid !important;
    grid-template-columns: 1fr;
    width: 100%;
    gap: 8px;
  }

  .action-buttons .button,
  .action-buttons button {
    width: 100%;
  }

  .publish-repeat-field {
    grid-template-columns: 92px minmax(0, 1fr) !important;
    width: 100%;
  }

  .quick-add-form,
  .direct-add-form,
  .bulk-form,
  .collect-form {
    grid-template-columns: 1fr !important;
  }

  .quick-add-form .button,
  .direct-add-form .button,
  .bulk-form .button,
  .collect-form .button {
    width: 100%;
  }

  .site-table {
    border-collapse: separate;
    border-spacing: 0 10px;
  }

  .site-table thead {
    display: none;
  }

  .site-table tbody,
  .site-table tr,
  .site-table td {
    display: block;
    width: 100% !important;
  }

  .site-table tr {
    position: relative;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .05);
  }

  .site-table td {
    border: 0;
    padding: 6px 0;
  }

  .site-table td:nth-child(1) {
    position: absolute;
    top: 12px;
    right: 12px;
    width: auto !important;
    padding: 0;
  }

  .site-table td:nth-child(2),
  .site-table td:nth-child(3) {
    display: inline-flex;
    width: auto !important;
    margin-right: 8px;
    padding: 0 0 8px;
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .site-table td:nth-child(2)::before {
    content: "NO ";
  }

  .site-table td:nth-child(3)::before {
    content: "ID ";
  }

  .site-table td:nth-child(4) {
    padding-right: 32px;
  }

  .site-table td:nth-child(4) .url-cell,
  .site-table .url-cell {
    font-size: 13px;
  }

  .site-table .url-cell a {
    color: #0f172a;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.35;
  }

  .site-table .url-cell small {
    font-size: 12px;
  }

  .site-table td:nth-child(5),
  .site-table td:nth-child(6),
  .site-table td:nth-child(7),
  .site-table td:nth-child(8) {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    align-items: start;
    gap: 8px;
    min-height: 30px;
  }

  .site-table td:nth-child(5)::before {
    content: "가입";
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .site-table td:nth-child(6)::before {
    content: "발행";
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .site-table td:nth-child(7)::before {
    content: "계정";
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .site-table td:nth-child(8)::before {
    content: "추가일";
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .site-table .hide-md,
  .site-table .hide-lg {
    display: grid !important;
  }

  .site-table .badge {
    width: fit-content;
    max-width: 100%;
  }

  .account-cell strong,
  .account-cell small {
    overflow-wrap: anywhere;
  }

  .site-table .action-cell {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding-top: 10px;
    border-top: 1px solid var(--line2);
  }

  .site-table .action-cell details,
  .site-table .action-cell form {
    min-width: 0;
  }

  .site-table .action-cell summary,
  .site-table .danger-button {
    min-height: 38px;
  }

  .site-table .edit-form {
    position: relative;
    z-index: 2;
    grid-column: 1 / -1;
    width: 100%;
    margin-top: 8px;
  }

  .pagination,
  .pager {
    gap: 8px;
  }

  .pagination a,
  .pager a {
    flex: 1;
    justify-content: center;
  }

  .mobile-card-table {
    border-collapse: separate;
    border-spacing: 0 10px;
  }

  .mobile-card-table thead {
    display: none;
  }

  .mobile-card-table tbody,
  .mobile-card-table tr,
  .mobile-card-table td {
    display: block;
    width: 100% !important;
  }

  .mobile-card-table tr {
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .05);
  }

  .mobile-card-table td {
    display: grid !important;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 8px;
    border: 0;
    padding: 7px 0;
    font-size: 13px;
    overflow-wrap: anywhere;
  }

  .mobile-card-table td::before {
    content: attr(data-label);
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .mobile-card-table .url-cell a,
  .mobile-card-table .text-cell strong {
    font-size: 13px;
    line-height: 1.38;
  }

  .mobile-card-table .action-cell form,
  .mobile-card-table .action-cell button,
  .mobile-card-table td[data-label="수정"] button {
    width: 100%;
  }

  .mobile-card-table input,
  .mobile-card-table select {
    min-height: 38px;
  }

  .admin-user-table td,
  .access-log-table td,
  .login-log-table td,
  .history-table td {
    vertical-align: top;
  }

  .access-log-table td[data-label="UA"],
  .login-log-table td[data-label="UA"] {
    grid-template-columns: 42px minmax(0, 1fr);
  }
}

/* Telegram verification guide */
.telegram-guide-layout {
  display: grid;
  gap: 14px;
  max-width: 920px;
}

.telegram-status-card,
.telegram-step-card,
.telegram-help-panel {
  background: #fff;
  border: 1px solid #dfe8f4;
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .06);
}

.telegram-status-card {
  display: grid;
  gap: 6px;
  padding: 22px;
  background:
    linear-gradient(135deg, rgba(29, 78, 216, .10), transparent 44%),
    #fff;
}

.telegram-status-card span {
  color: #64748b;
  font-weight: 900;
}

.telegram-status-card strong {
  color: #0f172a;
  font-size: 36px;
  line-height: 1;
}

.telegram-status-card p {
  margin: 8px 0 0;
  color: #475569;
}

.telegram-step-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 14px;
  padding: 20px;
}

.telegram-step-card.primary-step {
  border-color: rgba(29, 78, 216, .28);
}

.step-number {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #0f172a;
  color: #fff;
  font-weight: 950;
}

.telegram-step-card h2,
.telegram-help-panel h2 {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 20px;
}

.telegram-step-card p,
.telegram-help-panel li {
  color: #475569;
  line-height: 1.65;
}

.bot-id-box,
.verify-code-box,
.code-guide {
  width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
  border-radius: 12px;
  font-weight: 950;
}

.bot-id-box {
  margin: 12px 0;
  padding: 14px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 22px;
}

.verify-code-box {
  margin: 12px 0 8px;
  padding: 16px;
  border: 1px dashed #94a3b8;
  background: #f8fafc;
  color: #0f172a;
  font-size: 26px;
  letter-spacing: 1px;
}

.code-guide {
  margin: 8px 0;
  padding: 14px;
  border: 1px solid #e2e8f0;
  background: #111827;
  color: #fff;
  font-size: 18px;
  white-space: pre-wrap;
}

.telegram-help-panel {
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(20, 184, 166, .11), transparent 42%),
    #fff;
}

.telegram-help-panel ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
}

@media (max-width: 620px) {
  .telegram-status-card,
  .telegram-step-card,
  .telegram-help-panel {
    border-radius: 14px;
  }

  .telegram-step-card {
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .step-number {
    width: 36px;
    height: 36px;
  }

  .telegram-status-card strong {
    font-size: 32px;
  }

  .bot-id-box,
  .verify-code-box {
    font-size: 20px;
  }

  .code-guide {
    font-size: 16px;
  }
}

/* Mobile header final override */
@media (max-width: 760px) {
  .topbar {
    width: 100% !important;
    min-height: 60px !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 10px !important;
    padding: 10px 12px !important;
    border-bottom: 1px solid #e2e8f0 !important;
    background: #fff !important;
  }

  .topbar .brand {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    justify-content: flex-start !important;
    margin: 0 !important;
  }

  .topbar .brand-logo {
    width: 30px !important;
    height: 30px !important;
  }

  .topbar .brand-text {
    max-width: 52vw !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    font-size: 18px !important;
    line-height: 1 !important;
  }

  .topbar .mobile-menu-toggle {
    flex: 0 0 auto !important;
    width: auto !important;
    min-width: 82px !important;
    max-width: none !important;
    min-height: 40px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 7px !important;
    padding: 8px 13px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #0f172a !important;
    color: #fff !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .18) !important;
  }

  .topbar .mobile-menu-toggle span {
    display: none !important;
  }

  .topbar .mobile-menu-toggle::before {
    content: "☰";
    display: inline-block;
    color: #fff;
    font-size: 18px;
    font-weight: 900;
    line-height: 1;
  }

  .topbar .mobile-menu-toggle b {
    display: inline !important;
    color: #fff !important;
    font-size: 14px !important;
    font-weight: 950 !important;
    line-height: 1 !important;
  }

  .global-metric-row {
    width: 100% !important;
    max-width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    padding: 10px !important;
    margin: 0 !important;
    overflow: visible !important;
    background: #f8fafc !important;
  }

  .global-metric-row .metric {
    width: auto !important;
    min-width: 0 !important;
    min-height: 58px !important;
    display: grid !important;
    align-content: center !important;
    gap: 2px !important;
    padding: 10px 12px !important;
    border-radius: 13px !important;
    background: #fff !important;
  }

  .global-metric-row .metric strong {
    font-size: 20px !important;
    line-height: 1 !important;
  }

  .global-metric-row .metric span {
    margin: 0 !important;
    font-size: 12px !important;
    line-height: 1.2 !important;
  }

  .page {
    width: 100% !important;
    padding: 18px 11px 38px !important;
  }

  .official-hero,
  .jj-hero,
  .home-hero {
    padding-top: 22px !important;
  }
}

@media (max-width: 390px) {
  .topbar .brand-text {
    max-width: 46vw !important;
    font-size: 17px !important;
  }

  .topbar .mobile-menu-toggle {
    min-width: 76px !important;
    padding: 8px 11px !important;
  }

  .global-metric-row {
    gap: 7px !important;
    padding: 8px !important;
  }
}

/* Dashboard onboarding cards */
.dashboard-start-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px;
  margin-bottom: 16px;
  border: 1px solid #dfe8f4;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(29, 78, 216, .10), transparent 44%),
    linear-gradient(315deg, rgba(20, 184, 166, .10), transparent 38%),
    #fff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .07);
}

.dashboard-start-panel h2 {
  margin: 4px 0 6px;
  color: #0f172a;
  font-size: 24px;
}

.dashboard-start-panel p {
  margin: 0;
  color: #475569;
  line-height: 1.6;
}

.dashboard-action-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.dashboard-action-card {
  position: relative;
  min-height: 250px;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 20px;
  border: 1px solid #dfe8f4;
  border-radius: 16px;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .065);
  text-decoration: none;
  overflow: hidden;
}

.dashboard-action-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 5px;
  background: linear-gradient(90deg, #1d4ed8, #14b8a6);
}

.dashboard-action-card:hover {
  text-decoration: none;
  transform: translateY(-1px);
  transition: transform .16s ease;
}

.dashboard-action-card .action-kicker {
  width: fit-content;
  min-width: 38px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: #0f172a;
  color: #fff;
  font-size: 13px;
  font-weight: 950;
}

.dashboard-action-card strong {
  font-size: 22px;
  font-weight: 950;
}

.dashboard-action-card p {
  margin: 0;
  color: #475569;
  line-height: 1.58;
}

.dashboard-action-card small {
  display: block;
  color: #64748b;
  font-weight: 800;
  line-height: 1.45;
}

.dashboard-action-card form {
  align-self: end;
  margin: 6px 0 0;
}

.dashboard-action-card form .button {
  width: 100%;
}

.dashboard-action-card.import-card {
  border-color: rgba(29, 78, 216, .32);
  background:
    linear-gradient(135deg, rgba(29, 78, 216, .10), transparent 46%),
    #fff;
}

@media (max-width: 1100px) {
  .dashboard-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .dashboard-start-panel {
    align-items: stretch;
    flex-direction: column;
    padding: 16px;
  }

  .dashboard-start-panel .button {
    width: 100%;
  }

  .dashboard-action-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .dashboard-action-card {
    min-height: 0;
    padding: 17px;
  }

  .dashboard-action-card strong {
    font-size: 21px;
  }
}

@media (max-width: 420px) {
  .global-metric-row,
  .filter-tabs {
    grid-template-columns: 1fr;
  }

  .site-table td:nth-child(5),
  .site-table td:nth-child(6),
  .site-table td:nth-child(7),
  .site-table td:nth-child(8) {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .mobile-card-table td {
    grid-template-columns: 62px minmax(0, 1fr);
  }
}

.site-search-panel {
  background: #fff;
  border: 1px solid #d9e2ef;
  border-radius: 12px;
  padding: 16px;
  margin: 14px 0;
  box-shadow: 0 10px 28px rgba(15, 23, 42, .04);
}

.site-search-form {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  gap: 10px;
  align-items: end;
}

.site-search-form label {
  display: grid;
  gap: 6px;
  font-weight: 800;
  color: #0f172a;
}

.site-search-form input {
  width: 100%;
  min-height: 42px;
  border: 1px solid #d6dfec;
  border-radius: 10px;
  padding: 0 13px;
  font-size: 15px;
}

.site-search-panel .helper-text {
  margin: 9px 0 0;
  color: #64748b;
  font-size: 13px;
}

@media (max-width: 720px) {
  .site-search-panel {
    padding: 12px;
  }

  .site-search-form {
    grid-template-columns: 1fr;
  }

  .site-search-form .button {
    width: 100%;
    justify-content: center;
  }
}

/* Mobile-first site management UX */
.mobile-domain {
  display: none;
}

.mobile-site-dock {
  display: none;
}

@media (max-width: 720px) {
  body:has(.mobile-site-dock:not([hidden])) .page {
    padding-bottom: 166px;
  }

  .sites-page-head {
    align-items: center;
    margin-bottom: 10px;
  }

  .sites-page-head h1 {
    font-size: 24px;
  }

  .site-filter-tabs {
    display: flex !important;
    gap: 7px;
    margin: 0 -10px 12px;
    padding: 0 10px 4px;
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .site-filter-tabs::-webkit-scrollbar {
    display: none;
  }

  .site-filter-tabs .badge {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 7px 11px;
    border-radius: 999px;
    white-space: nowrap;
  }

  .site-search-panel {
    border-radius: 10px;
    margin-bottom: 10px;
  }

  .site-search-panel .helper-text {
    display: none;
  }

  .sites-panel {
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  .sites-panel .section-title {
    padding: 0 2px;
    margin-bottom: 8px;
  }

  .sites-panel .section-title h2 {
    font-size: 17px;
  }

  .site-action-head {
    position: sticky;
    top: 0;
    z-index: 7;
    margin: 0 0 10px;
    padding: 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 8px 22px rgba(15, 23, 42, .08);
    backdrop-filter: blur(8px);
  }

  .site-action-head .select-all-label {
    justify-content: flex-start;
    min-height: 38px;
    padding: 0 2px;
  }

  .site-action-head .action-buttons {
    gap: 7px;
  }

  .publish-repeat-field {
    display: grid !important;
    grid-template-columns: 1fr 82px;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid #dbe3ef;
    border-radius: 9px;
    background: #f8fafc;
  }

  .publish-repeat-field span {
    color: #334155;
    font-size: 13px;
    font-weight: 900;
  }

  .publish-repeat-field input {
    min-height: 34px;
    text-align: center;
    font-weight: 900;
  }

  .mobile-site-table {
    display: block;
    border-collapse: separate !important;
    border-spacing: 0 10px !important;
    background: transparent;
  }

  .mobile-site-table thead {
    display: none !important;
  }

  .mobile-site-table tbody {
    display: grid !important;
    gap: 10px;
  }

  .mobile-site-table tr {
    position: relative;
    display: grid !important;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "url check"
      "status status"
      "account account"
      "date date"
      "actions actions";
    gap: 8px 10px;
    padding: 14px !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .07) !important;
  }

  .mobile-site-table td {
    display: block !important;
    width: auto !important;
    min-width: 0;
    border: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }

  .mobile-site-table td::before {
    content: none !important;
  }

  .mobile-site-table .mobile-check-cell {
    grid-area: check;
    align-self: start;
    padding-top: 2px !important;
  }

  .mobile-site-table .site-check {
    width: 24px;
    height: 24px;
    accent-color: var(--accent);
  }

  .mobile-site-table .site-no-cell,
  .mobile-site-table .site-id-cell {
    display: inline-flex !important;
    grid-row: 1;
    grid-column: 1;
    align-self: start;
    width: fit-content !important;
    margin-top: 32px;
    margin-right: 6px;
    padding: 3px 7px !important;
    border-radius: 999px;
    background: #eef2f7 !important;
    color: #475569;
    font-size: 11px;
    font-weight: 900;
  }

  .mobile-site-table .site-id-cell {
    margin-left: 52px;
  }

  .mobile-site-table .url-cell {
    grid-area: url;
    padding-right: 2px !important;
  }

  .mobile-domain {
    display: block;
    max-width: calc(100vw - 98px);
    overflow: hidden;
    color: #0f172a;
    font-size: 17px;
    font-weight: 950;
    line-height: 1.22;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-site-table .board-url {
    display: block;
    max-width: calc(100vw - 92px);
    margin-top: 28px;
    overflow: hidden;
    color: #64748b;
    font-size: 12px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-site-table .main-url {
    display: none;
  }

  .mobile-site-table .note {
    display: block;
    margin-top: 8px;
    padding: 8px 9px;
    border-radius: 8px;
    background: #fff7ed;
    color: #9a3412 !important;
    font-size: 12px;
    line-height: 1.42;
  }

  .mobile-site-table td[data-label="가입"],
  .mobile-site-table td[data-label="발행"] {
    display: flex !important;
    grid-area: status;
    align-items: center;
    gap: 7px;
  }

  .mobile-site-table td[data-label="발행"] {
    margin-left: 92px;
  }

  .mobile-site-table td[data-label="가입"]::before,
  .mobile-site-table td[data-label="발행"]::before,
  .mobile-site-table td[data-label="계정"]::before,
  .mobile-site-table td[data-label="추가일"]::before {
    display: inline-block !important;
    min-width: 42px;
    content: attr(data-label) !important;
    color: #64748b;
    font-size: 12px;
    font-weight: 900;
  }

  .mobile-site-table td[data-label="계정"] {
    display: grid !important;
    grid-area: account;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 7px;
    align-items: start;
  }

  .mobile-site-table .account-cell strong,
  .mobile-site-table .account-cell small,
  .mobile-site-table .account-cell span {
    grid-column: 2;
  }

  .mobile-site-table td[data-label="추가일"] {
    display: grid !important;
    grid-area: date;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 7px;
    color: #64748b;
    font-size: 12px;
  }

  .mobile-site-table .hide-md,
  .mobile-site-table .hide-lg {
    display: grid !important;
  }

  .mobile-site-table .badge {
    width: fit-content;
    min-height: 25px;
    padding: 4px 8px;
    font-size: 11px;
  }

  .mobile-site-table .action-cell {
    display: grid !important;
    grid-area: actions;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 4px;
  }

  .mobile-site-table .action-cell summary,
  .mobile-site-table .danger-button {
    min-height: 40px;
    border-radius: 9px;
  }

  .mobile-site-table .edit-form {
    grid-column: 1 / -1;
    width: 100%;
  }

  .mobile-site-dock {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 78px;
    z-index: 50;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    padding: 10px;
    border: 1px solid rgba(15, 23, 42, .14);
    border-radius: 14px;
    background: rgba(15, 23, 42, .96);
    color: #fff;
    box-shadow: 0 18px 38px rgba(15, 23, 42, .35);
  }

  .mobile-site-dock[hidden] {
    display: none !important;
  }

  .mobile-site-dock strong {
    white-space: nowrap;
    font-size: 14px;
  }

  .mobile-site-dock div {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
  }

  .mobile-site-dock .button {
    min-height: 42px;
    border-radius: 10px;
    padding: 8px 9px;
    font-size: 13px;
  }
}

@media (max-width: 420px) {
  .mobile-site-table td[data-label="발행"] {
    margin-left: 0;
  }

  .mobile-site-table td[data-label="가입"],
  .mobile-site-table td[data-label="발행"] {
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .mobile-site-dock {
    grid-template-columns: 1fr;
  }
}

/* Mobile UX reset v2: app-like navigation, compact metrics, readable cards */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 760px) {
  html,
  body {
    background: #f3f6fa;
  }

  body {
    padding-bottom: 72px;
  }

  .topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    min-height: 0;
    padding: 9px 12px 8px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 8px 22px rgba(15, 23, 42, .08);
  }

  .brand {
    justify-content: center;
    min-height: 34px;
    font-size: 18px;
  }

  .brand-logo {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }

  .main-nav {
    display: flex !important;
    gap: 7px;
    margin: 0 -12px;
    padding: 0 12px 2px;
    overflow-x: auto;
    flex-wrap: nowrap !important;
    scrollbar-width: none;
  }

  .main-nav::-webkit-scrollbar {
    display: none;
  }

  .main-nav a,
  .main-nav button {
    flex: 0 0 auto;
    min-height: 31px;
    padding: 6px 10px;
    border: 1px solid #d9e2ef;
    border-radius: 999px;
    background: #fff;
    color: #334155;
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
  }

  .main-nav a.active {
    border-color: #0f172a;
    background: #0f172a;
    color: #fff;
  }

  .main-nav form {
    flex: 0 0 auto !important;
  }

  .main-nav form[action$="logout"],
  .main-nav form[action*="logout"] {
    display: none;
  }

  .mobile-bottom-nav {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 8px;
    z-index: 80;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(44px, 1fr));
    gap: 5px;
    padding: 7px;
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 18px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 18px 42px rgba(15, 23, 42, .22);
    backdrop-filter: blur(10px);
  }

  .mobile-bottom-nav a {
    display: grid;
    place-items: center;
    min-height: 42px;
    border-radius: 13px;
    color: #475569;
    font-size: 10.5px;
    font-weight: 950;
    text-decoration: none;
  }

  .mobile-bottom-nav a.active {
    background: #0f172a;
    color: #fff;
  }

  .page {
    width: 100%;
    padding: 12px 10px 92px;
  }

  .page-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    margin: 4px 0 10px;
  }

  .page-head h1 {
    margin: 2px 0 0;
    font-size: 23px;
    line-height: 1.2;
  }

  .eyebrow {
    font-size: 11px;
  }

  .head-count {
    padding: 7px 10px;
    font-size: 13px;
  }

  .global-metric-row {
    position: static !important;
    display: flex !important;
    gap: 7px;
    margin: 0;
    padding: 9px 10px 7px;
    overflow-x: auto;
    background: #eef3f9;
    border-bottom: 1px solid #dbe3ef;
    scrollbar-width: none;
  }

  .global-metric-row::-webkit-scrollbar {
    display: none;
  }

  .global-metric-row .metric {
    flex: 0 0 98px;
    display: grid;
    gap: 2px;
    min-height: 54px;
    padding: 8px 10px;
    border-radius: 12px;
    background: #fff;
  }

  .global-metric-row .metric strong {
    font-size: 18px;
    line-height: 1.05;
  }

  .global-metric-row .metric span {
    margin: 0;
    font-size: 11px;
    line-height: 1.15;
  }

  .filter-tabs,
  .history-tabs,
  .segmented {
    display: flex !important;
    gap: 7px;
    margin: 0 -10px 10px;
    padding: 0 10px 4px;
    overflow-x: auto;
    flex-wrap: nowrap !important;
    scrollbar-width: none;
  }

  .filter-tabs::-webkit-scrollbar,
  .history-tabs::-webkit-scrollbar,
  .segmented::-webkit-scrollbar {
    display: none;
  }

  .filter-tabs .badge,
  .history-tabs .badge,
  .segmented a {
    flex: 0 0 auto !important;
    justify-content: center;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 999px;
    white-space: nowrap;
  }

  .dashboard-grid,
  .quick-menu-grid,
  .home-action-grid,
  .metric-grid.compact {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px;
  }

  .dash-card,
  .quick-menu-card,
  .home-action-card,
  .panel,
  .table-panel,
  .control-block,
  .direct-site-panel,
  .post-panel,
  .import-admin-panel,
  .fold-panel {
    border-radius: 13px !important;
    padding: 13px !important;
    box-shadow: 0 8px 22px rgba(15, 23, 42, .06);
  }

  .dash-card strong,
  .metric strong {
    font-size: 22px;
  }

  .home-action-card {
    min-height: 104px;
  }

  .section-title {
    align-items: center;
    margin-bottom: 9px;
  }

  .section-title h2 {
    font-size: 17px !important;
  }

  .table-summary,
  .toolbar,
  .table-actions {
    font-size: 13px;
  }

  .control-panel,
  .template-grid,
  .collect-form,
  .quick-add-form,
  .bulk-form,
  .post-setting-form,
  .keyword-combo-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 9px !important;
  }

  input,
  textarea,
  select,
  button,
  .button {
    min-height: 42px;
    border-radius: 10px;
    font-size: 14px;
  }

  textarea {
    min-height: 118px;
  }

  .keyword-combo-grid textarea,
  .post-keyword-input {
    min-height: 104px;
  }

  .table-wrap {
    overflow: visible !important;
  }

  .data-table.mobile-card-table,
  .data-table.candidate-table,
  .point-history-table,
  .admin-user-table,
  .access-log-table,
  .login-log-table,
  .history-table {
    display: block;
    width: 100%;
    border-collapse: separate !important;
    border-spacing: 0 10px !important;
    background: transparent;
  }

  .data-table.mobile-card-table thead,
  .data-table.candidate-table thead,
  .point-history-table thead,
  .admin-user-table thead,
  .access-log-table thead,
  .login-log-table thead,
  .history-table thead {
    display: none !important;
  }

  .data-table.mobile-card-table tbody,
  .data-table.candidate-table tbody,
  .point-history-table tbody,
  .admin-user-table tbody,
  .access-log-table tbody,
  .login-log-table tbody,
  .history-table tbody {
    display: grid !important;
    gap: 10px;
  }

  .data-table.mobile-card-table tr,
  .data-table.candidate-table tr,
  .point-history-table tr,
  .admin-user-table tr,
  .access-log-table tr,
  .login-log-table tr,
  .history-table tr {
    display: grid !important;
    gap: 7px;
    padding: 13px !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 13px !important;
    background: #fff !important;
    box-shadow: 0 8px 22px rgba(15, 23, 42, .06);
  }

  .data-table.mobile-card-table td,
  .data-table.candidate-table td,
  .point-history-table td,
  .admin-user-table td,
  .access-log-table td,
  .login-log-table td,
  .history-table td {
    display: grid !important;
    grid-template-columns: 68px minmax(0, 1fr);
    gap: 8px;
    width: 100% !important;
    border: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    color: #334155;
    font-size: 13px;
    line-height: 1.42;
    overflow-wrap: anywhere;
  }

  .data-table.mobile-card-table td::before,
  .data-table.candidate-table td::before,
  .point-history-table td::before,
  .admin-user-table td::before,
  .access-log-table td::before,
  .login-log-table td::before,
  .history-table td::before {
    content: attr(data-label);
    color: #64748b;
    font-size: 12px;
    font-weight: 950;
  }

  .data-table td.url-cell,
  .data-table td.text-cell,
  .history-table td[data-label="사이트"],
  .history-table td[data-label="사유"] {
    grid-template-columns: 1fr !important;
  }

  .data-table td.url-cell::before,
  .data-table td.text-cell::before,
  .history-table td[data-label="사이트"]::before,
  .history-table td[data-label="사유"]::before {
    content: none !important;
  }

  .url-cell a,
  .text-cell strong {
    color: #0f172a;
    font-size: 14px;
    font-weight: 950;
    line-height: 1.38;
  }

  .url-cell small,
  .text-cell small,
  .data-table small {
    font-size: 12px;
    line-height: 1.45;
  }

  .badge {
    width: fit-content;
    max-width: 100%;
  }

  .action-cell,
  .head-actions {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .action-cell form,
  .action-cell button,
  .head-actions .button {
    width: 100%;
  }

  .pagination {
    position: sticky;
    bottom: 74px;
    z-index: 20;
    margin: 12px 0;
    padding: 8px;
    border: 1px solid #dbe3ef;
    border-radius: 999px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 10px 24px rgba(15, 23, 42, .12);
  }

  .candidate-table td:first-child,
  .point-history-table td:first-child,
  .history-table td:first-child,
  .admin-user-table td:first-child,
  .access-log-table td:first-child,
  .login-log-table td:first-child {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 7px !important;
    border-bottom: 1px solid #edf1f6 !important;
    color: #0f172a;
    font-weight: 950;
  }

  .candidate-table td:first-child::before,
  .point-history-table td:first-child::before,
  .history-table td:first-child::before,
  .admin-user-table td:first-child::before,
  .access-log-table td:first-child::before,
  .login-log-table td:first-child::before {
    content: attr(data-label) !important;
  }

  .history-table .action-cell {
    margin-top: 4px;
  }

  .history-table .action-cell .button {
    width: 100%;
    min-height: 40px;
  }

  .access-log-table td[data-label="UA"],
  .login-log-table td[data-label="UA"],
  .access-log-table td[data-label="리퍼러"] {
    grid-template-columns: 1fr !important;
    max-height: 88px;
    overflow: hidden;
    padding: 8px !important;
    border-radius: 9px;
    background: #f8fafc !important;
  }

  .access-log-table td[data-label="UA"]::before,
  .login-log-table td[data-label="UA"]::before,
  .access-log-table td[data-label="리퍼러"]::before {
    content: attr(data-label) !important;
    margin-bottom: 2px;
  }

  .admin-user-table input,
  .admin-user-table select {
    min-height: 38px;
  }

  .admin-setting-panel {
    display: grid;
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .admin-setting-panel form,
  .admin-setting-panel button {
    width: 100%;
  }

  .admin-publish-cell {
    grid-template-columns: 1fr !important;
    padding: 10px !important;
    border-radius: 10px;
    background: #f8fafc !important;
  }

  .admin-publish-cell::before {
    content: attr(data-label) !important;
  }

  .admin-publish-controls {
    grid-template-columns: repeat(2, minmax(118px, 1fr));
  }

  .admin-publish-cell .button {
    width: 100%;
  }

  .admin-user-table td[data-label="수정"] {
    grid-template-columns: 1fr !important;
  }

  .admin-user-table td[data-label="수정"]::before {
    content: none !important;
  }

  .admin-user-table td[data-label="수정"] .button {
    width: 100%;
  }

  .point-summary-grid {
    grid-template-columns: 1fr 1fr !important;
  }

  .point-balance-card {
    grid-column: 1 / -1;
    background: #0f172a !important;
    color: #fff !important;
  }

  .point-balance-card span {
    color: #dbeafe !important;
  }

  .point-history-table td[data-label="포인트"] {
    font-size: 18px;
    font-weight: 950;
  }

  .point-history-table td[data-label="사유"] {
    grid-template-columns: 1fr !important;
    padding: 8px !important;
    border-radius: 9px;
    background: #f8fafc !important;
  }

  .point-history-table td[data-label="사유"]::before {
    content: attr(data-label) !important;
    margin-bottom: 2px;
  }

  .point-history-table td[data-label="사이트"] a {
    font-weight: 950;
  }
}

@media (max-width: 430px) {
  .dashboard-grid,
  .quick-menu-grid,
  .home-action-grid,
  .metric-grid.compact {
    grid-template-columns: 1fr !important;
  }

  .data-table.mobile-card-table td,
  .data-table.candidate-table td,
  .point-history-table td,
  .admin-user-table td,
  .access-log-table td,
  .login-log-table td,
  .history-table td {
    grid-template-columns: 58px minmax(0, 1fr);
  }
}
﻿
/* Admin user management layout */
.admin-users-page {
  overflow: hidden;
}

.admin-page-head {
  align-items: flex-end;
}

.admin-user-wrap {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.admin-user-table {
  min-width: 1120px;
  table-layout: fixed;
}

.admin-user-table th,
.admin-user-table td {
  padding: 12px 10px;
  vertical-align: top;
}

.admin-col-user { width: 210px; }
.admin-col-role { width: 150px; }
.admin-col-publish { width: 270px; }
.admin-col-access { width: 230px; }
.admin-col-date { width: 145px; }
.admin-col-manage { width: 210px; }

.admin-user-main {
  overflow-wrap: anywhere;
}

.admin-user-main strong,
.admin-access-cell strong {
  display: block;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.35;
}

.admin-user-main span,
.admin-user-main small,
.admin-access-cell small,
.admin-date-cell small {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.admin-pill-line,
.admin-publish-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.admin-pill-line strong,
.admin-publish-top strong {
  color: #0f172a;
  font-size: 18px;
  font-weight: 950;
}

.admin-publish-cell {
  display: grid;
  gap: 9px;
}

.admin-publish-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-publish-controls label,
.admin-edit-grid label {
  display: grid;
  gap: 5px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.admin-publish-controls input {
  min-height: 38px;
  padding: 7px 10px;
  text-align: center;
  font-size: 16px;
  font-weight: 950;
}

.admin-edit-details summary {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  color: #1d4ed8;
  font-weight: 900;
  cursor: pointer;
  list-style: none;
}

.admin-edit-details summary::-webkit-details-marker {
  display: none;
}

.admin-edit-details[open] summary {
  margin-bottom: 10px;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.admin-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}

.admin-edit-grid input,
.admin-edit-grid select,
.admin-user-table input,
.admin-user-table select {
  min-height: 38px;
  padding: 8px 10px;
  font-size: 13px;
}

.admin-full-field {
  grid-column: 1 / -1;
}

.admin-wide-button {
  width: 100%;
}

.admin-hidden-forms {
  display: none;
}

@media (max-width: 760px) {
  .admin-setting-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-setting-panel form,
  .admin-setting-panel .button {
    width: 100%;
  }

  .admin-user-wrap {
    overflow: visible;
    border: 0;
    background: transparent;
  }

  .admin-user-table {
    min-width: 0;
  }

  .admin-user-table.mobile-card-table tr {
    padding: 14px;
    border-radius: 12px;
  }

  .admin-user-table.mobile-card-table td {
    grid-template-columns: 78px minmax(0, 1fr);
    padding: 8px 0;
  }

  .admin-user-table.mobile-card-table td[data-label="회원"] {
    grid-template-columns: 1fr;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line2);
  }

  .admin-user-table.mobile-card-table td[data-label="회원"]::before {
    display: none;
  }

  .admin-user-main strong {
    font-size: 16px;
  }

  .admin-publish-controls,
  .admin-edit-grid {
    grid-template-columns: 1fr;
  }

  .admin-publish-top {
    align-items: stretch;
  }

  .admin-publish-top .button {
    flex: 1;
  }
}
﻿
/* Publish setting sets: show all sets vertically */
.post-set-guide {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: #f8fafc;
}

.post-set-guide strong {
  color: #0f172a;
  font-size: 15px;
  white-space: nowrap;
}

.post-set-guide span {
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
}

.post-set-stack {
  display: grid;
  gap: 18px;
}

.post-set-panel {
  scroll-margin-top: 82px;
}

.post-set-title {
  align-items: flex-start;
}

.post-set-title h2 {
  margin-bottom: 4px !important;
}

.post-set-title span {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.post-set-title .js-post-save-result {
  min-width: 140px;
  text-align: right;
  color: #047857;
  font-weight: 900;
}

.post-set-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 12px;
}

.post-set-footer .token-help + .token-help {
  margin-top: 6px !important;
}

.post-set-footer .js-post-save-button {
  min-width: 150px;
}

@media (max-width: 760px) {
  .post-set-guide {
    align-items: flex-start;
    flex-direction: column;
  }

  .post-set-title {
    align-items: stretch;
    flex-direction: column;
  }

  .post-set-title .js-post-save-result {
    min-width: 0;
    text-align: left;
  }

  .post-set-footer {
    grid-template-columns: 1fr;
  }

  .post-set-footer .js-post-save-button {
    width: 100%;
  }
}


.admin-bulk-publish-panel {
  align-items: end;
}

.admin-bulk-publish-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(128px, 150px)) auto;
  align-items: end;
  gap: 10px;
}

.admin-bulk-publish-form label {
  display: grid;
  gap: 5px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.admin-bulk-publish-form input {
  width: 100%;
  min-width: 118px;
  min-height: 42px;
  padding: 8px 12px;
  text-align: center;
  font-size: 16px;
  font-weight: 950;
}

.admin-col-check,
.admin-user-check-cell {
  width: 46px;
  text-align: center;
}

.admin-user-check,
#admin-user-check-all {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

@media (max-width: 760px) {
  .admin-bulk-publish-panel {
    align-items: stretch;
  }

  .admin-bulk-publish-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-bulk-publish-form .button {
    grid-column: 1 / -1;
    width: 100%;
  }

  .admin-user-check-cell {
    justify-content: flex-end;
  }
}


/* 2026 SEO landing refresh */
.jj-hero{position:relative;display:grid;grid-template-columns:minmax(0,1.05fr) minmax(400px,.95fr);gap:34px;align-items:center;min-height:680px;padding:64px 0 46px;}
.jj-hero::before{content:"";position:absolute;inset:18px -20px auto auto;width:min(560px,48vw);height:420px;background:linear-gradient(135deg,rgba(29,78,216,.14),rgba(15,118,110,.10));border-radius:8px;z-index:-1;}
.jj-hero-copy h1{margin:8px 0 10px;color:#07111f;font-size:72px;line-height:1;letter-spacing:0;font-weight:950;}
.jj-hero-title{max-width:760px;margin:0 0 16px;color:#12305f;font-size:28px;line-height:1.32;font-weight:950;letter-spacing:0;}
.jj-hero-lead{max-width:780px;margin:0;color:#475569;font-size:18px;line-height:1.82;}
.jj-hero-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:28px;}
.jj-hero-actions .button{min-height:44px;padding:10px 16px;font-size:15px;}
.jj-trust-row{display:flex;gap:8px;flex-wrap:wrap;margin-top:24px;}
.jj-trust-row span{display:inline-flex;align-items:center;min-height:32px;padding:7px 11px;border:1px solid #d8e3f0;border-radius:999px;background:#fff;color:#334155;font-size:13px;font-weight:900;box-shadow:0 5px 14px rgba(15,23,42,.04);}
.jj-dashboard-preview{min-width:0;border:1px solid #dbe4f0;border-radius:8px;background:#fff;box-shadow:0 26px 64px rgba(15,23,42,.16);overflow:hidden;}
.jj-preview-head{display:flex;align-items:center;gap:8px;padding:16px 18px;border-bottom:1px solid #edf1f6;background:#f8fafc;}
.jj-preview-head span{width:10px;height:10px;border-radius:50%;background:#cbd5e1}.jj-preview-head span:nth-child(1){background:#ef4444}.jj-preview-head span:nth-child(2){background:#f59e0b}.jj-preview-head span:nth-child(3){background:#10b981}.jj-preview-head strong{margin-left:auto;color:#0f172a;font-size:14px;}
.jj-preview-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:18px;}
.jj-preview-metrics div{min-width:0;padding:16px;border:1px solid #edf1f6;border-radius:8px;background:linear-gradient(180deg,#fff,#fbfdff);}
.jj-preview-metrics b{display:block;color:#64748b;font-size:12px}.jj-preview-metrics strong{display:block;margin-top:6px;color:#0f172a;font-size:25px}.jj-preview-metrics span{display:block;margin-top:4px;color:#64748b;font-size:12px;font-weight:800;}
.jj-preview-table{padding:0 18px 18px}.jj-preview-table>div{display:grid;grid-template-columns:minmax(0,1fr) 72px 58px;gap:10px;align-items:center;padding:13px 0;border-bottom:1px solid #edf1f6;font-size:14px}.jj-preview-table span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#334155;font-weight:800}.jj-preview-table em{font-style:normal;font-size:12px;font-weight:950}.jj-preview-table strong{font-size:12px;color:#64748b}.jj-preview-table .ok{color:var(--ok)}.jj-preview-table .warn{color:#92400e}.jj-preview-table .bad{color:var(--bad)}
.jj-section{margin:26px 0}.jj-section-head{display:grid;grid-template-columns:minmax(0,.92fr) minmax(280px,.68fr);gap:18px;align-items:end;margin-bottom:16px}.jj-section-head.compact{display:block}.jj-section-head h2,.jj-how h2,.jj-seo-copy h2,.jj-cta h2{margin:4px 0 0;color:#0f172a;font-size:34px;line-height:1.25;letter-spacing:0}.jj-section-head p:last-child,.jj-how-copy p,.jj-seo-copy p,.jj-cta p{margin:0;color:#64748b;font-size:15px;line-height:1.78;}
.jj-free{padding:24px;border:1px solid #dfe7f1;border-radius:8px;background:#fff;box-shadow:0 12px 28px rgba(15,23,42,.05)}.jj-free-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.jj-free-grid article{padding:18px;border:1px solid #e6edf6;border-radius:8px;background:#f8fafc}.jj-free-grid strong,.jj-feature-grid strong{display:block;color:#0f172a;font-size:17px}.jj-free-grid p,.jj-feature-grid p{margin:9px 0 0;color:#64748b;font-size:14px;line-height:1.68;}
.jj-feature-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.jj-feature-grid article{min-width:0;padding:20px;border:1px solid #dfe7f1;border-radius:8px;background:#fff;box-shadow:0 8px 18px rgba(15,23,42,.04)}.jj-feature-grid span{display:inline-grid;place-items:center;width:34px;height:28px;margin-bottom:12px;border-radius:999px;background:#eff6ff;color:#1d4ed8;font-size:12px;font-weight:950;}
.jj-how{display:grid;grid-template-columns:minmax(260px,.42fr) minmax(0,.58fr);gap:20px;margin:28px 0;padding:26px;border:1px solid #dfe7f1;border-radius:8px;background:#0f172a;color:#fff}.jj-how h2{color:#fff}.jj-how-copy p{color:#d6dee9}.jj-step-list{display:grid;gap:10px;margin:0;padding:0;list-style:none}.jj-step-list li{display:grid;grid-template-columns:40px minmax(0,1fr);gap:4px 12px;align-items:start;padding:14px;border:1px solid rgba(255,255,255,.13);border-radius:8px;background:rgba(255,255,255,.06)}.jj-step-list b{grid-row:1/3;display:grid;place-items:center;width:34px;height:34px;border-radius:999px;background:#fff;color:#0f172a;font-weight:950}.jj-step-list strong{color:#fff}.jj-step-list span{color:#d6dee9;font-size:14px;line-height:1.55;}
.jj-seo-copy{display:grid;grid-template-columns:minmax(260px,.42fr) minmax(0,.58fr);gap:18px;padding:24px;border:1px solid #dfe7f1;border-radius:8px;background:#fff}.jj-seo-copy p{font-size:16px!important;color:#475569!important;}
.jj-faq{margin:28px 0}.jj-faq-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.jj-faq details{padding:16px;border:1px solid #dfe7f1;border-radius:8px;background:#fff}.jj-faq summary{cursor:pointer;color:#0f172a;font-weight:950}.jj-faq p{margin:10px 0 0;color:#64748b;font-size:14px;line-height:1.7;}
.jj-cta{display:flex;align-items:center;justify-content:space-between;gap:20px;margin:30px 0 8px;padding:26px;border-radius:8px;background:#07111f;color:#fff}.jj-cta h2{color:#fff}.jj-cta p{color:#d6dee9}.jj-cta .button:not(.primary){background:transparent;color:#fff;border-color:rgba(255,255,255,.24)}
@media(max-width:1080px){.jj-hero{grid-template-columns:1fr;min-height:0}.jj-dashboard-preview{max-width:760px}.jj-section-head,.jj-how,.jj-seo-copy{grid-template-columns:1fr}.jj-feature-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.jj-hero-copy h1{font-size:58px}.jj-hero-title{font-size:24px}}
@media(max-width:760px){.jj-hero{padding:34px 0 28px;gap:20px}.jj-hero::before{display:none}.jj-hero-copy h1{font-size:44px}.jj-hero-title{font-size:21px}.jj-hero-lead{font-size:16px}.jj-hero-actions .button{flex:1 1 100%;}.jj-trust-row span{flex:1 1 auto;justify-content:center}.jj-preview-metrics{grid-template-columns:1fr}.jj-preview-table>div{grid-template-columns:minmax(0,1fr) 58px 44px}.jj-section-head h2,.jj-how h2,.jj-seo-copy h2,.jj-cta h2{font-size:26px}.jj-section-head{grid-template-columns:1fr}.jj-free{padding:18px}.jj-free-grid,.jj-feature-grid,.jj-faq-grid{grid-template-columns:1fr}.jj-how,.jj-seo-copy,.jj-cta{padding:18px}.jj-cta{display:grid}.jj-step-list li{grid-template-columns:34px minmax(0,1fr)}}


/* Landing visual polish: Korean typography, color rhythm, tighter spacing */
body{
  font-family:"Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", Arial, sans-serif!important;
  word-break:keep-all;
  background:#f3f7fb;
}
.eyebrow{letter-spacing:0!important;color:#0f766e!important;}
.topbar{
  background:rgba(255,255,255,.92)!important;
  backdrop-filter:blur(14px);
  border-bottom-color:#d8e2ee!important;
}
.topbar .main-nav a,
.topbar .main-nav button{
  border-radius:999px;
}
.page{width:min(1180px,100%)!important;}
.jj-hero{
  min-height:650px!important;
  grid-template-columns:minmax(0,1.02fr) minmax(420px,.98fr)!important;
  gap:42px!important;
  padding:72px 0 52px!important;
}
.jj-hero::before{
  inset:44px -32px auto auto!important;
  width:min(520px,44vw)!important;
  height:360px!important;
  background:linear-gradient(135deg,#dff7f1 0%,#e9f1ff 48%,#fff2d8 100%)!important;
  border:1px solid rgba(15,23,42,.05);
  box-shadow:0 24px 70px rgba(29,78,216,.09);
}
.jj-hero-copy{max-width:760px;}
.jj-hero-copy .eyebrow{
  display:inline-flex;
  align-items:center;
  min-height:34px;
  padding:7px 12px;
  border:1px solid #bde8df;
  border-radius:999px;
  background:#ecfdf8;
  color:#0f766e!important;
  font-size:13px;
}
.jj-hero-copy h1{
  margin:18px 0 12px!important;
  color:#07111f!important;
  font-size:76px!important;
  line-height:1.02!important;
  font-weight:950!important;
  text-wrap:balance;
}
.jj-hero-title{
  max-width:680px!important;
  margin:0 0 18px!important;
  color:#10213f!important;
  font-size:31px!important;
  line-height:1.35!important;
  font-weight:950!important;
  text-wrap:balance;
}
.jj-hero-lead{
  max-width:690px!important;
  color:#43546a!important;
  font-size:18px!important;
  line-height:1.86!important;
}
.jj-hero-actions{gap:12px!important;margin-top:30px!important;}
.jj-hero-actions .button{
  min-height:48px!important;
  padding:11px 18px!important;
  border-radius:999px!important;
  font-size:15px!important;
  box-shadow:0 8px 18px rgba(15,23,42,.07);
}
.jj-hero-actions .button.primary{
  background:#13294b!important;
  border-color:#13294b!important;
  color:#fff!important;
}
.jj-hero-actions .button.primary:hover{
  background:#0f766e!important;
  border-color:#0f766e!important;
  text-decoration:none;
}
.jj-color-tags span:nth-child(1){border-color:#bae6fd;background:#eff9ff;color:#075985;}
.jj-color-tags span:nth-child(2){border-color:#bbf7d0;background:#f0fdf4;color:#166534;}
.jj-color-tags span:nth-child(3){border-color:#fed7aa;background:#fff7ed;color:#9a3412;}
.jj-color-tags span:nth-child(4){border-color:#ddd6fe;background:#f5f3ff;color:#5b21b6;}
.jj-dashboard-preview{
  border-radius:14px!important;
  border-color:#cad7e5!important;
  box-shadow:0 28px 76px rgba(13,29,53,.18)!important;
  transform:translateY(8px);
}
.jj-preview-head{background:#101827!important;color:#fff!important;border-bottom:0!important;}
.jj-preview-head strong{color:#e9f2ff!important;}
.jj-preview-metrics{background:#fff;}
.jj-preview-metrics div{
  border-radius:12px!important;
  border-color:#e2eaf4!important;
  background:#fbfdff!important;
}
.jj-preview-metrics div:nth-child(1){border-top:4px solid #0ea5e9!important;}
.jj-preview-metrics div:nth-child(2){border-top:4px solid #10b981!important;}
.jj-preview-metrics div:nth-child(3){border-top:4px solid #f59e0b!important;}
.jj-preview-metrics strong{font-size:27px!important;}
.jj-preview-table>div{min-height:48px;}
.jj-section{margin:34px 0!important;}
.jj-section-head{margin-bottom:20px!important;}
.jj-section-head h2,
.jj-how h2,
.jj-seo-copy h2,
.jj-cta h2{
  font-size:35px!important;
  line-height:1.28!important;
  color:#10213f!important;
  text-wrap:balance;
}
.jj-section-head p:last-child,
.jj-how-copy p,
.jj-seo-copy p,
.jj-cta p{
  font-size:16px!important;
  line-height:1.82!important;
  color:#526274!important;
}
.jj-band-warm{
  background:linear-gradient(135deg,#fffaf0 0%,#fff 56%,#f1fbf7 100%)!important;
  border-color:#eadfc4!important;
}
.jj-service-band{
  padding:26px;
  border:1px solid #dbe7f3;
  border-radius:14px;
  background:#fff;
  box-shadow:0 18px 46px rgba(15,23,42,.06);
}
.jj-free-grid article,
.jj-feature-grid article,
.jj-faq details{
  border-radius:12px!important;
  transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.jj-free-grid article:hover,
.jj-feature-grid article:hover,
.jj-faq details:hover{
  transform:translateY(-2px);
  border-color:#bfd2ea!important;
  box-shadow:0 16px 34px rgba(15,23,42,.08)!important;
}
.jj-free-grid article:nth-child(1){background:#eff9ff!important;border-color:#bae6fd!important;}
.jj-free-grid article:nth-child(2){background:#f0fdf4!important;border-color:#bbf7d0!important;}
.jj-free-grid article:nth-child(3){background:#fff7ed!important;border-color:#fed7aa!important;}
.jj-feature-grid article span{
  width:38px!important;
  height:30px!important;
  background:#10213f!important;
  color:#fff!important;
}
.jj-feature-grid article:nth-child(2n) span{background:#0f766e!important;}
.jj-feature-grid article:nth-child(3n) span{background:#d97706!important;}
.jj-how{
  border-radius:14px!important;
  background:#10213f!important;
  box-shadow:0 20px 54px rgba(16,33,63,.18);
}
.jj-step-list li{
  border-radius:12px!important;
  background:rgba(255,255,255,.075)!important;
}
.jj-step-list b{background:#f7c948!important;color:#10213f!important;}
.jj-seo-copy{
  border-radius:14px!important;
  background:#fff!important;
  border-left:6px solid #0f766e!important;
  box-shadow:0 14px 36px rgba(15,23,42,.05);
}
.jj-band-blue{
  padding:24px;
  border-radius:14px;
  background:#eef6ff;
  border:1px solid #cfe1f7;
}
.jj-faq details{background:#fff!important;}
.jj-faq summary{font-size:16px;line-height:1.45;}
.jj-cta{
  border-radius:16px!important;
  background:linear-gradient(135deg,#10213f 0%,#0f766e 100%)!important;
  box-shadow:0 24px 60px rgba(15,23,42,.18);
}
.jj-cta h2{color:#fff!important;}
.jj-cta p{color:#e5f3ef!important;}
@media(max-width:1080px){
  .jj-hero{grid-template-columns:1fr!important;}
  .jj-dashboard-preview{max-width:820px;}
  .jj-hero-copy h1{font-size:58px!important;}
  .jj-hero-title{font-size:26px!important;}
}
@media(max-width:760px){
  .page{padding-left:14px!important;padding-right:14px!important;}
  .jj-hero{padding:34px 0 28px!important;}
  .jj-hero-copy h1{font-size:45px!important;}
  .jj-hero-title{font-size:22px!important;}
  .jj-hero-lead{font-size:16px!important;line-height:1.78!important;}
  .jj-section-head h2,.jj-how h2,.jj-seo-copy h2,.jj-cta h2{font-size:27px!important;}
  .jj-service-band,.jj-band-blue{padding:18px!important;}
}

/* Admin users UX reset 20260712 */
.admin-users-page {
  max-width: 100%;
  overflow: visible;
}

.admin-users-page .section-title {
  gap: 12px;
  flex-wrap: wrap;
}

.admin-users-page .head-actions {
  margin-left: auto;
}

.admin-users-page .admin-setting-panel {
  align-items: stretch;
  gap: 14px;
  padding: 16px;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.admin-users-page .admin-setting-panel > div {
  min-width: 0;
}

.admin-users-page .admin-setting-panel small {
  display: block;
  margin-top: 5px;
  color: #64748b;
  line-height: 1.45;
}

.admin-users-page .admin-bulk-publish-panel {
  display: grid;
  grid-template-columns: minmax(240px, .9fr) minmax(0, 1.6fr);
  align-items: end;
}

.admin-users-page .admin-bulk-publish-form {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(96px, 120px)) repeat(3, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
}

.admin-users-page .admin-bulk-publish-form input {
  min-width: 0;
  width: 100%;
}

.admin-users-page .admin-bulk-publish-form .button {
  min-width: 0;
  width: 100%;
  white-space: normal;
  line-height: 1.25;
}

.admin-user-wrap {
  max-width: 100%;
  overflow: visible;
  border: 0;
  background: transparent;
}

.admin-user-wrap.table-wrap {
  overflow-x: visible;
}

.admin-user-table {
  width: 100%;
  min-width: 0 !important;
  border-collapse: separate;
  border-spacing: 0 10px;
  table-layout: fixed;
  background: transparent;
}

.admin-user-table thead th {
  padding: 8px 10px;
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 11px;
  text-transform: uppercase;
}

.admin-user-table tbody tr {
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .055);
}

.admin-user-table tbody td {
  border-top: 1px solid #e7edf5;
  border-bottom: 1px solid #e7edf5;
  background: #fff;
}

.admin-user-table tbody td:first-child {
  border-left: 1px solid #e7edf5;
  border-radius: 10px 0 0 10px;
}

.admin-user-table tbody td:last-child {
  border-right: 1px solid #e7edf5;
  border-radius: 0 10px 10px 0;
}

.admin-user-table tr:hover td {
  background: #fbfdff;
}

.admin-col-check,
.admin-user-check-cell { width: 42px; }
.admin-col-user { width: 24%; }
.admin-col-role { width: 15%; }
.admin-col-publish { width: 29%; }
.admin-col-access { width: 17%; }
.admin-col-date { display: none; }
.admin-date-cell { display: none; }
.admin-col-manage { width: 15%; }

.admin-user-main strong {
  font-size: 15px;
  font-weight: 950;
}

.admin-user-main span,
.admin-user-main small,
.admin-access-cell small,
.admin-date-cell small {
  max-width: 100%;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.admin-pill-line,
.admin-publish-top {
  align-items: flex-start;
  justify-content: flex-start;
}

.admin-pill-line {
  flex-direction: column;
  gap: 5px;
}

.admin-publish-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
}

.admin-publish-controls {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.admin-publish-controls input,
.admin-edit-grid input,
.admin-edit-grid select,
.admin-user-table input,
.admin-user-table select {
  min-width: 0;
  width: 100%;
}

.admin-user-table .button,
.admin-user-table button {
  min-width: 0;
  width: 100%;
  white-space: normal;
  line-height: 1.25;
}

.admin-user-table .button.small {
  min-height: 32px;
  padding: 6px 8px;
  font-size: 12px;
}

.admin-publish-cell,
.admin-manage-cell {
  gap: 8px;
}

.admin-edit-details summary {
  min-height: 38px;
  border-radius: 7px;
}

.admin-edit-grid {
  grid-template-columns: 1fr;
}

.admin-manage-cell .button.danger {
  margin-top: 8px;
}

@media (max-width: 1180px) {
  .admin-users-page .admin-bulk-publish-panel {
    grid-template-columns: 1fr;
  }

  .admin-users-page .admin-bulk-publish-form {
    grid-template-columns: repeat(2, minmax(90px, 120px)) repeat(2, minmax(0, 1fr));
  }

  .admin-users-page .admin-bulk-publish-form .button:last-child {
    grid-column: 1 / -1;
  }

  .admin-col-access,
  .admin-access-cell {
    display: none;
  }

  .admin-col-user { width: 30%; }
  .admin-col-role { width: 18%; }
  .admin-col-publish { width: 34%; }
  .admin-col-manage { width: 18%; }
}

@media (max-width: 760px) {
  .admin-users-page .admin-setting-panel,
  .admin-users-page .admin-bulk-publish-panel {
    padding: 14px;
  }

  .admin-users-page .admin-bulk-publish-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-users-page .admin-bulk-publish-form .button {
    grid-column: 1 / -1;
  }

  .admin-user-table {
    border-spacing: 0 12px;
  }

  .admin-user-table thead {
    display: none;
  }

  .admin-user-table.mobile-card-table tr {
    display: block;
    padding: 14px;
    border: 1px solid #e7edf5;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(15,23,42,.05);
  }

  .admin-user-table.mobile-card-table td {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 8px;
    border: 0 !important;
    border-radius: 0 !important;
    padding: 8px 0;
    background: transparent !important;
  }

  .admin-user-table.mobile-card-table td::before {
    content: attr(data-label);
    color: #64748b;
    font-size: 12px;
    font-weight: 950;
  }

  .admin-user-table.mobile-card-table td[data-label="??"] {
    grid-template-columns: 1fr;
    padding-top: 0;
    padding-bottom: 12px;
    border-bottom: 1px solid #edf2f7 !important;
  }

  .admin-user-table.mobile-card-table td[data-label="??"]::before {
    display: none;
  }

  .admin-user-table.mobile-card-table .admin-access-cell,
  .admin-user-table.mobile-card-table .admin-date-cell {
    display: grid;
  }

  .admin-publish-top,
  .admin-publish-controls {
    grid-template-columns: 1fr;
  }

  .admin-user-check-cell {
    grid-template-columns: 82px auto !important;
    justify-content: stretch;
  }

  .admin-user-check-cell input {
    justify-self: start;
  }
}

/* Guide page and onboarding helpers */
.guide-flow-panel,
.guide-check-panel,
.dashboard-guide-strip {
  background: #fff;
  border: 1px solid #dfe8f4;
  border-radius: 16px;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .07);
}

/* Admin v2 */
.admin-v2-page {
  max-width: 100%;
  padding: 20px;
  background: #f6f8fb;
  border: 1px solid #dfe7f2;
  border-radius: 14px;
}

.admin-v2-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.admin-v2-head h1 {
  margin: 2px 0 6px;
  color: #071327;
  font-size: 30px;
  letter-spacing: 0;
}

.admin-v2-head p {
  margin: 0;
  color: #526174;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
}

.admin-v2-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.admin-v2-kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.admin-v2-kpis article {
  min-width: 0;
  padding: 14px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .045);
}

.admin-v2-kpis span,
.setting-label {
  display: block;
  color: #007c72;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.admin-v2-kpis strong {
  display: block;
  margin-top: 5px;
  color: #071327;
  font-size: 24px;
  font-weight: 950;
  line-height: 1.1;
}

.admin-v2-kpis small {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.admin-v2-toolbar {
  display: grid;
  grid-template-columns: minmax(240px, .75fr) minmax(0, 1.55fr);
  gap: 14px;
  align-items: end;
  margin-bottom: 14px;
  padding: 16px;
  border: 1px solid #dfe7f2;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .045);
}

.admin-v2-toolbar h2,
.admin-setting-card h2 {
  margin: 0 0 5px;
  color: #071327;
  font-size: 18px;
  letter-spacing: 0;
}

.admin-v2-toolbar p,
.admin-setting-card p {
  margin: 0;
  color: #526174;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.55;
}

.admin-v2-bulk-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(104px, 128px)) repeat(3, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
}

.admin-v2-bulk-form label,
.admin-setting-form label {
  display: grid;
  gap: 5px;
  color: #526174;
  font-size: 12px;
  font-weight: 950;
}

.admin-v2-bulk-form input,
.admin-setting-form input {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid #cfd9e8;
  border-radius: 8px;
  background: #fff;
  color: #071327;
  font-size: 15px;
  font-weight: 900;
}

.admin-v2-bulk-form .button,
.admin-setting-form .button,
.admin-setting-links .button {
  width: 100%;
  min-width: 0;
  white-space: normal;
}

.admin-v2-table-wrap {
  overflow: visible;
}

.admin-v2-table {
  width: 100%;
  min-width: 0 !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0 8px;
  background: transparent;
}

.admin-v2-table th {
  padding: 7px 10px;
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 11px;
  font-weight: 950;
  text-align: left;
}

.admin-v2-table td {
  padding: 12px 10px;
  border-top: 1px solid #dfe7f2;
  border-bottom: 1px solid #dfe7f2;
  background: #fff;
  vertical-align: top;
}

.admin-v2-table tbody tr {
  box-shadow: 0 8px 20px rgba(15, 23, 42, .045);
}

.admin-v2-table td:first-child {
  border-left: 1px solid #dfe7f2;
  border-radius: 10px 0 0 10px;
}

.admin-v2-table td:last-child {
  border-right: 1px solid #dfe7f2;
  border-radius: 0 10px 10px 0;
}

.admin-v2-table .admin-col-check,
.admin-v2-table .admin-user-check-cell {
  width: 44px;
}

.admin-v2-table th:nth-child(2) { width: 22%; }
.admin-v2-table th:nth-child(3) { width: 15%; }
.admin-v2-table th:nth-child(4) { width: 30%; }
.admin-v2-table th:nth-child(5) { width: 18%; }
.admin-v2-table th:nth-child(6) { width: 15%; }

.admin-user-main,
.admin-access-cell,
.admin-v2-stack,
.admin-publish-cell,
.admin-manage-cell {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.admin-user-main strong,
.admin-access-cell strong {
  color: #071327;
  font-size: 15px;
  font-weight: 950;
  word-break: break-word;
}

.admin-user-main span,
.admin-user-main small,
.admin-access-cell small,
.admin-v2-stack small {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.admin-v2-page .admin-pill-line,
.admin-v2-page .admin-publish-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.admin-v2-page .admin-pill-line {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.admin-v2-page .admin-pill-line strong,
.admin-v2-page .admin-publish-top strong {
  color: #071327;
  font-size: 17px;
  font-weight: 950;
}

.admin-v2-page .admin-publish-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-v2-page .admin-publish-controls label,
.admin-v2-page .admin-edit-grid label {
  display: grid;
  gap: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 950;
}

.admin-v2-page .admin-publish-controls input,
.admin-v2-page .admin-edit-grid input,
.admin-v2-page .admin-edit-grid select,
.admin-v2-table input,
.admin-v2-table select {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  padding: 7px 10px;
  border: 1px solid #cfd9e8;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 900;
}

.admin-v2-table .button,
.admin-v2-table button {
  width: 100%;
  min-width: 0;
  white-space: normal;
}

.admin-v2-table .button.small {
  min-height: 30px;
  padding: 6px 8px;
  font-size: 12px;
}

.admin-v2-page .admin-edit-details summary {
  min-height: 36px;
  padding: 9px 10px;
  border: 1px solid #cfd9e8;
  border-radius: 8px;
  background: #f8fafc;
  color: #071327;
  font-weight: 950;
  cursor: pointer;
}

.admin-v2-page .admin-edit-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin: 9px 0;
}

.admin-full-field {
  grid-column: 1 / -1;
}

.admin-wide-button {
  width: 100%;
}

.admin-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.admin-setting-card {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 18px;
  border: 1px solid #dfe7f2;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .055);
}

.setting-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.admin-setting-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.admin-setting-form .button {
  grid-column: 1 / -1;
}

.admin-setting-form .setting-checkline {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 9px;
  align-items: center;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #dbe4f0;
  border-radius: 10px;
  background: #f8fafc;
}

.admin-setting-form .setting-checkline input {
  width: 18px;
  min-height: 18px;
  padding: 0;
  accent-color: #1d4ed8;
}

.admin-setting-form .setting-checkline span {
  color: #0f172a;
  font-size: 13px;
  font-weight: 950;
}

.admin-setting-form .setting-checkline small {
  grid-column: 2;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.setting-note {
  margin: 10px 0 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 900;
}

.setting-note.danger {
  background: #fff1f2;
  border: 1px solid #fecdd3;
  color: #be123c;
}

.public-seo-hero {
  align-items: center;
}

.public-keyword-panel {
  justify-content: flex-start;
  align-content: center;
  padding: 22px;
  border: 1px solid #dfe7f1;
  border-radius: 8px;
  background: linear-gradient(135deg, #f8fafc 0%, #eef6ff 100%);
}

.public-keyword-panel span {
  border-color: #cbdff7;
  background: #fff;
  color: #0f172a;
}

.public-card-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.public-seo-flow p {
  margin: 10px 0 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.7;
}

.public-related-links .official-keywords a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 8px 11px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px;
  background: rgba(255,255,255,.08);
  color: #f8fafc;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.public-related-links .official-keywords a:hover {
  background: rgba(255,255,255,.15);
}

@media(max-width:1080px) {
  .public-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media(max-width:660px) {
  .public-card-grid {
    grid-template-columns: 1fr;
  }
  .public-keyword-panel {
    padding: 16px;
  }
}

.admin-setting-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

@media (max-width: 1180px) {
  .admin-v2-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-v2-toolbar {
    grid-template-columns: 1fr;
  }

  .admin-v2-bulk-form {
    grid-template-columns: repeat(2, minmax(104px, 130px)) repeat(2, minmax(0, 1fr));
  }

  .admin-v2-bulk-form .button:last-child {
    grid-column: 1 / -1;
  }

  .admin-v2-table th:nth-child(5),
  .admin-v2-table td[data-label="접속 정보"] {
    display: none;
  }

  .admin-v2-table th:nth-child(2) { width: 28%; }
  .admin-v2-table th:nth-child(3) { width: 18%; }
  .admin-v2-table th:nth-child(4) { width: 34%; }
  .admin-v2-table th:nth-child(6) { width: 20%; }
}

@media (max-width: 760px) {
  .admin-v2-page {
    padding: 12px;
  }

  .admin-v2-head {
    display: grid;
  }

  .admin-v2-actions {
    justify-content: stretch;
  }

  .admin-v2-actions .button {
    flex: 1 1 calc(50% - 8px);
  }

  .admin-v2-kpis,
  .admin-settings-grid {
    grid-template-columns: 1fr;
  }

  .admin-v2-toolbar {
    padding: 14px;
  }

  .admin-v2-bulk-form,
  .admin-setting-form,
  .admin-setting-links {
    grid-template-columns: 1fr;
  }

  .admin-v2-table {
    border-spacing: 0 12px;
  }

  .admin-v2-table thead {
    display: none;
  }

  .admin-v2-table.mobile-card-table tr {
    display: block;
    padding: 14px;
    border: 1px solid #dfe7f2;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(15,23,42,.05);
  }

  .admin-v2-table.mobile-card-table td {
    display: grid !important;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 8px;
    padding: 9px 0;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
  }

  .admin-v2-table.mobile-card-table td::before {
    content: attr(data-label);
    color: #64748b;
    font-size: 12px;
    font-weight: 950;
  }

  .admin-v2-table.mobile-card-table td[data-label="회원"] {
    grid-template-columns: 1fr;
    padding-top: 0;
    padding-bottom: 12px;
    border-bottom: 1px solid #edf2f7 !important;
  }

  .admin-v2-table.mobile-card-table td[data-label="회원"]::before {
    display: none;
  }

  .admin-v2-page .admin-publish-top,
  .admin-v2-page .admin-publish-controls {
    grid-template-columns: 1fr;
  }
}

/* Admin users table v3 - desktop-first management table */
.admin-table-page {
  max-width: 100%;
  padding: 20px;
  background: #f6f8fb;
  border: 1px solid #dfe7f2;
  border-radius: 14px;
}

.admin-table-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.admin-table-head h1 {
  margin: 2px 0 6px;
  color: #071327;
  font-size: 30px;
  letter-spacing: 0;
}

.admin-table-head p {
  margin: 0;
  color: #526174;
  font-size: 14px;
  font-weight: 800;
}

.admin-table-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.admin-table-kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.admin-table-kpis article {
  min-width: 0;
  padding: 14px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
}

.admin-table-kpis span {
  display: block;
  color: #007c72;
  font-size: 11px;
  font-weight: 950;
}

.admin-table-kpis strong {
  display: block;
  margin-top: 5px;
  color: #071327;
  font-size: 24px;
  font-weight: 950;
}

.admin-table-kpis small {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.admin-table-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, .75fr) minmax(0, 1.55fr);
  gap: 14px;
  align-items: end;
  margin-bottom: 14px;
  padding: 14px 16px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
}

.admin-table-toolbar h2 {
  margin: 0 0 5px;
  color: #071327;
  font-size: 18px;
}

.admin-table-toolbar p {
  margin: 0;
  color: #526174;
  font-size: 13px;
  font-weight: 800;
}

.admin-bulk-inline-form {
  display: grid;
  grid-template-columns: 130px 130px repeat(3, minmax(132px, 1fr));
  gap: 8px;
  align-items: end;
}

.admin-bulk-inline-form label {
  display: grid;
  gap: 5px;
  color: #526174;
  font-size: 12px;
  font-weight: 900;
}

.admin-bulk-inline-form input {
  width: 100%;
  min-width: 0;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid #cfd9e8;
  border-radius: 8px;
  background: #fff;
  font-size: 15px;
  font-weight: 900;
}

.admin-bulk-inline-form .button {
  width: 100%;
  min-width: 0;
  white-space: nowrap;
}

.admin-users-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
}

.admin-users-table {
  width: 100%;
  min-width: 1320px;
  border-collapse: collapse;
  table-layout: fixed;
  background: #fff;
}

.admin-users-table th,
.admin-users-table td {
  vertical-align: top;
  border-bottom: 1px solid #e7edf5;
}

.admin-users-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 10px 9px;
  background: #f1f5fa;
  color: #526174;
  font-size: 12px;
  font-weight: 950;
  text-align: left;
  white-space: nowrap;
}

.admin-users-table td {
  padding: 10px 9px;
  color: #071327;
  font-size: 13px;
  font-weight: 800;
}

.admin-users-table tbody tr:hover td {
  background: #f8fbff;
}

.admin-users-table .check-col {
  width: 42px;
  text-align: center;
}

.admin-users-table th:nth-child(2) { width: 210px; }
.admin-users-table th:nth-child(3) { width: 80px; }
.admin-users-table th:nth-child(4) { width: 135px; }
.admin-users-table th:nth-child(5) { width: 110px; }
.admin-users-table th:nth-child(6) { width: 230px; }
.admin-users-table th:nth-child(7) { width: 150px; }
.admin-users-table th:nth-child(8) { width: 230px; }
.admin-users-table th:nth-child(9) { width: 200px; }

.admin-users-table .member-col,
.admin-users-table .point-col,
.admin-users-table .count-col,
.admin-users-table .access-col,
.admin-users-table .manage-col {
  display: table-cell !important;
}

.admin-users-table .member-col strong,
.admin-users-table .point-col strong,
.admin-users-table .count-col strong,
.admin-users-table .access-col strong {
  display: block;
  color: #071327;
  font-size: 14px;
  font-weight: 950;
  word-break: break-word;
}

.admin-users-table .member-col span,
.admin-users-table .member-col small,
.admin-users-table .point-col small,
.admin-users-table .access-col small,
.admin-users-table .muted {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  word-break: break-word;
}

.admin-users-table .member-col .button.small {
  margin-top: 8px;
}

.admin-users-table .repeat-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 7px;
}

.admin-users-table .repeat-row label,
.admin-users-table .admin-edit-panel label {
  display: grid;
  gap: 4px;
  color: #64748b;
  font-size: 11px;
  font-weight: 950;
}

.admin-users-table input,
.admin-users-table select {
  width: 100%;
  min-width: 0;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid #cfd9e8;
  border-radius: 7px;
  background: #fff;
  color: #071327;
  font-size: 13px;
  font-weight: 900;
}

.admin-users-table .button,
.admin-users-table button {
  width: 100%;
  min-width: 0;
  min-height: 34px;
  padding: 7px 9px;
  border-radius: 7px;
  white-space: nowrap;
}

.admin-users-table .button.small {
  min-height: 30px;
  padding: 5px 8px;
  font-size: 12px;
}

.admin-users-table .admin-edit-details {
  margin-bottom: 8px;
}

.admin-users-table .admin-edit-details summary {
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid #cfd9e8;
  border-radius: 7px;
  background: #f8fafc;
  color: #071327;
  font-size: 13px;
  font-weight: 950;
  text-align: center;
  cursor: pointer;
  list-style: none;
}

.admin-users-table .admin-edit-details summary::-webkit-details-marker {
  display: none;
}

.admin-users-table .admin-edit-panel {
  display: grid;
  gap: 7px;
  margin-top: 8px;
  padding: 8px;
  border: 1px solid #e7edf5;
  border-radius: 8px;
  background: #f8fafc;
}

.admin-hidden-forms {
  display: none;
}

@media (max-width: 1180px) {
  .admin-table-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-table-toolbar {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .admin-table-page {
    padding: 12px;
  }

  .admin-table-head {
    display: grid;
  }

  .admin-table-actions {
    justify-content: stretch;
  }

  .admin-table-actions .button {
    flex: 1 1 calc(50% - 8px);
  }

  .admin-table-kpis {
    grid-template-columns: 1fr;
  }

  .admin-bulk-inline-form {
    grid-template-columns: 1fr;
  }

  .admin-users-table {
    min-width: 1320px;
  }
}

/* Admin users wide table + live editable post settings */
.admin-users-page.admin-table-page {
  width: calc(100vw - 28px);
  max-width: none;
  margin-left: calc(50% - 50vw + 14px);
  margin-right: calc(50% - 50vw + 14px);
}

.admin-users-page .admin-users-table-wrap {
  overflow-x: visible !important;
}

.admin-users-page .admin-users-table {
  min-width: 0 !important;
  width: 100%;
  table-layout: fixed;
}

.admin-users-page .admin-users-table th,
.admin-users-page .admin-users-table td {
  padding: 9px 7px;
  font-size: 12px;
}

.admin-users-page .admin-users-table th {
  white-space: normal;
}

.admin-users-page .admin-users-table .button,
.admin-users-page .admin-users-table button {
  white-space: normal;
  line-height: 1.2;
}

.admin-users-page .admin-table-kpis {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.admin-users-page .admin-users-table .check-col { width: 3%; }
.admin-users-page .admin-users-table th:nth-child(2) { width: 13%; }
.admin-users-page .admin-users-table th:nth-child(3) { width: 7%; }
.admin-users-page .admin-users-table th:nth-child(4) { width: 6%; }
.admin-users-page .admin-users-table th:nth-child(5) { width: 9%; }
.admin-users-page .admin-users-table th:nth-child(6) { width: 8%; }
.admin-users-page .admin-users-table th:nth-child(7) { width: 14%; }
.admin-users-page .admin-users-table th:nth-child(8) { width: 10%; }
.admin-users-page .admin-users-table th:nth-child(9) { width: 18%; }
.admin-users-page .admin-users-table th:nth-child(10) { width: 12%; }

.admin-users-page .admin-users-table .member-col strong,
.admin-users-page .admin-users-table .point-col strong,
.admin-users-page .admin-users-table .count-col strong,
.admin-users-page .admin-users-table .access-col strong {
  font-size: 13px;
}

.admin-users-page .admin-users-table .member-col span,
.admin-users-page .admin-users-table .member-col small,
.admin-users-page .admin-users-table .point-col small,
.admin-users-page .admin-users-table .access-col small,
.admin-users-page .admin-users-table .muted {
  font-size: 11px;
}

.admin-users-page .admin-bulk-inline-form {
  grid-template-columns: 120px 120px repeat(3, minmax(120px, 1fr));
}

.admin-post-settings-modal-card {
  width: min(1280px, calc(100vw - 48px));
  max-height: calc(100vh - 56px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.admin-post-settings-help {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
}

.admin-post-settings-editor {
  display: grid;
  gap: 14px;
  overflow-y: auto;
  padding-right: 4px;
}

.admin-post-setting-form {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #f8fafc;
}

.admin-post-setting-form-head,
.admin-post-setting-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.admin-post-setting-form-head strong {
  color: #071327;
  font-size: 17px;
  font-weight: 950;
}

.admin-post-setting-active {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: auto;
  color: #0f766e;
  font-size: 13px;
  font-weight: 950;
}

.admin-post-setting-active input {
  width: auto;
}

.admin-post-setting-form label {
  display: grid;
  gap: 6px;
  color: #526174;
  font-size: 12px;
  font-weight: 950;
}

.admin-post-setting-form input,
.admin-post-setting-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid #cfd9e8;
  border-radius: 8px;
  background: #fff;
  color: #071327;
  font-size: 13px;
  font-weight: 800;
}

.admin-post-setting-form textarea {
  resize: vertical;
}

.admin-post-setting-keywords {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.admin-post-setting-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-post-setting-footer small,
.admin-post-setting-footer span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.admin-post-setting-footer span {
  margin-left: auto;
}

.admin-post-setting-footer span.error {
  color: #b42318;
}

.admin-post-setting-footer .button {
  min-width: 140px;
}

.admin-campaign-panel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto minmax(120px, auto);
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding: 14px 16px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #fff;
}

.admin-campaign-panel h2 {
  margin: 0 0 5px;
  color: #071327;
  font-size: 18px;
}

.admin-campaign-panel p,
.campaign-status {
  margin: 0;
  color: #526174;
  font-size: 13px;
  font-weight: 800;
}

.campaign-switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
  cursor: pointer;
  user-select: none;
}

.campaign-switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.campaign-switch .switch-ui {
  width: 44px;
  height: 24px;
  position: relative;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #16a34a;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.08);
  transition: background .18s ease;
}

.campaign-switch .switch-ui::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 23px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, .22);
  transition: left .18s ease;
}

.campaign-switch input:not(:checked) + .switch-ui {
  background: #94a3b8;
}

.campaign-switch input:not(:checked) + .switch-ui::after {
  left: 3px;
}

.campaign-switch strong {
  color: #071327;
  font-size: 12px;
  font-weight: 950;
}

.campaign-switch-large {
  padding: 10px 12px;
  border: 1px solid #dfe7f2;
  border-radius: 10px;
  background: #f8fafc;
}

.campaign-switch-large strong {
  font-size: 14px;
}

.admin-users-mobile-list {
  display: none;
}

.admin-user-mobile-card {
  padding: 14px;
  border: 1px solid #dfe7f2;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(15, 23, 42, .05);
}

.mobile-user-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #edf2f7;
}

.mobile-user-select {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 5px 8px;
  border: 1px solid #dfe7f2;
  border-radius: 999px;
  background: #f8fafc;
  color: #526174;
  font-size: 12px;
  font-weight: 950;
}

.mobile-user-select input {
  width: auto;
  min-height: 0;
}

.mobile-user-card-head strong {
  display: block;
  color: #071327;
  font-size: 16px;
  font-weight: 950;
}

.mobile-user-card-head span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.mobile-user-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
}

.mobile-user-card-grid div {
  min-width: 0;
  padding: 10px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #edf2f7;
}

.mobile-user-card-grid span {
  display: block;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
}

.mobile-user-card-grid strong {
  display: block;
  margin-top: 4px;
  color: #071327;
  font-size: 13px;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.mobile-user-card-actions {
  display: grid;
  gap: 8px;
}

.mobile-user-card-actions form {
  display: grid;
  gap: 8px;
  margin: 0;
}

.mobile-repeat-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.mobile-repeat-row label {
  display: grid;
  gap: 5px;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
}

@media (max-width: 1180px) {
  .admin-post-setting-keywords {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .admin-users-page.admin-table-page {
    width: calc(100vw - 20px);
    margin-left: calc(50% - 50vw + 10px);
    margin-right: calc(50% - 50vw + 10px);
  }

  .admin-users-page .admin-users-table {
    min-width: 0 !important;
  }

  .admin-campaign-panel {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .admin-users-page .admin-table-toolbar {
    display: grid;
    gap: 10px;
  }

  .admin-users-page .admin-bulk-inline-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-users-page .admin-bulk-inline-form .button {
    grid-column: 1 / -1;
  }

  .admin-users-page .admin-users-table-wrap {
    display: none;
  }

  .admin-users-mobile-list {
    display: grid;
    gap: 12px;
  }

  .admin-post-setting-keywords,
  .admin-post-setting-links,
  .admin-post-setting-footer {
    grid-template-columns: 1fr;
  }

  .admin-post-setting-footer {
    align-items: stretch;
    flex-direction: column;
  }
}

.guide-flow-panel {
  padding: 24px;
  margin: 18px 0;
}

.guide-flow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.guide-flow-grid article {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 190px;
  padding: 18px;
  border: 1px solid #e4ecf7;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.guide-flow-grid article span {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #0f172a;
  color: #fff;
  font-weight: 900;
}

.guide-flow-grid article strong {
  color: #0f172a;
  font-size: 17px;
}

.guide-flow-grid article p,
.guide-check-panel p {
  color: #475569;
  line-height: 1.65;
}

.guide-card-button {
  align-self: end;
  width: fit-content;
  margin-top: 4px;
}

.guide-check-panel {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 22px;
  padding: 24px;
  margin: 18px 0;
  background:
    linear-gradient(135deg, rgba(20, 184, 166, .12), transparent 42%),
    #fff;
}

.guide-check-panel ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.guide-check-panel li {
  position: relative;
  padding: 12px 14px 12px 38px;
  border-radius: 12px;
  background: rgba(255,255,255,.78);
  border: 1px solid #e3ebf6;
  color: #334155;
}

.guide-check-panel li::before {
  content: "✓";
  position: absolute;
  left: 14px;
  top: 12px;
  color: #0f766e;
  font-weight: 950;
}

.dashboard-guide-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  margin: 16px 0;
  background:
    linear-gradient(135deg, rgba(14, 165, 233, .10), transparent 42%),
    linear-gradient(315deg, rgba(20, 184, 166, .10), transparent 38%),
    #fff;
}

.dashboard-guide-strip strong {
  display: block;
  margin-bottom: 4px;
  color: #0f172a;
  font-size: 18px;
}

.dashboard-guide-strip span {
  color: #475569;
}

.guide-strip-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.home-action-card.guide-action {
  border-color: rgba(20, 184, 166, .35);
  background:
    linear-gradient(135deg, rgba(20, 184, 166, .14), transparent 46%),
    #fff;
}

@media (max-width: 900px) {
  .guide-flow-grid,
  .guide-check-panel {
    grid-template-columns: 1fr;
  }

  .guide-flow-grid article {
    min-height: 0;
  }

  .dashboard-guide-strip {
    align-items: stretch;
    flex-direction: column;
  }

  .guide-strip-actions {
    justify-content: stretch;
  }

  .guide-strip-actions .button {
    flex: 1 1 160px;
  }
}

/* Mobile menu rebuild */
.mobile-menu-toggle,
.mobile-menu-backdrop,
.mobile-menu-panel {
  display: none;
}

@media (max-width: 760px) {
  body.mobile-menu-open {
    overflow: hidden;
  }

  .topbar {
    position: sticky;
    top: 0;
    z-index: 80;
    min-height: 62px;
    align-items: center !important;
    flex-direction: row !important;
    padding: 10px 14px !important;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(12px);
  }

  .brand {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #0f172a;
  }

  .brand-text {
    font-size: 18px;
    font-weight: 950;
    white-space: nowrap;
  }

  .topbar > .main-nav {
    display: none !important;
  }

  .mobile-menu-toggle {
    display: inline-grid;
    grid-template-columns: 18px auto;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 8px 12px;
    border: 1px solid #dbe5f1;
    border-radius: 999px;
    background: #0f172a;
    color: #fff;
    font-weight: 900;
  }

  .mobile-menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 3px 0;
    border-radius: 999px;
    background: #fff;
  }

  .mobile-menu-toggle b {
    font-size: 13px;
    line-height: 1;
  }

  .mobile-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 88;
    background: rgba(15, 23, 42, .46);
  }

  .mobile-menu-backdrop.is-open {
    display: block;
  }

  .mobile-menu-panel {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 89;
    display: flex;
    flex-direction: column;
    width: min(88vw, 390px);
    height: 100dvh;
    padding: 18px;
    background: #f8fafc;
    border-left: 1px solid #dbe5f1;
    box-shadow: -22px 0 46px rgba(15, 23, 42, .22);
    transform: translateX(102%);
    transition: transform .22s ease;
  }

  .mobile-menu-panel.is-open {
    transform: translateX(0);
  }

  .mobile-menu-panel:not(.is-open) {
    display: none;
  }

  .mobile-menu-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid #e2e8f0;
  }

  .mobile-menu-head strong {
    color: #0f172a;
    font-size: 18px;
    font-weight: 950;
  }

  .mobile-menu-close {
    min-height: 34px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #fff;
    font-size: 13px;
  }

  .mobile-menu-user {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 14px 0;
    padding: 14px;
    border: 1px solid #dbeafe;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(29,78,216,.10), rgba(20,184,166,.10));
  }

  .mobile-menu-user span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #334155;
    font-weight: 900;
  }

  .mobile-menu-user strong {
    color: #0f172a;
    font-size: 18px;
  }

  .mobile-menu-links {
    display: grid;
    gap: 8px;
    overflow-y: auto;
    padding: 4px 0 18px;
  }

  .mobile-menu-links a,
  .mobile-logout-form button {
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
    color: #0f172a;
    font-size: 15px;
    font-weight: 900;
    text-decoration: none;
  }

  .mobile-menu-links a::after {
    content: "›";
    color: #94a3b8;
    font-size: 22px;
    line-height: 1;
  }

  .mobile-menu-links a.important {
    border-color: #1d4ed8;
    background: #1d4ed8;
    color: #fff;
  }

  .mobile-menu-links a.important::after {
    color: rgba(255,255,255,.75);
  }

  .mobile-logout-form {
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid #e2e8f0;
  }

  .mobile-logout-form button {
    width: 100%;
    justify-content: center;
    border-color: #fecaca;
    color: #b42318;
  }

  .mobile-bottom-nav {
    display: none !important;
  }

  .global-metric-row {
    position: static !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px;
    padding: 10px;
    overflow-x: hidden !important;
  }

  .global-metric-row .metric {
    min-width: 0;
    flex: initial !important;
    min-height: 54px;
    border-radius: 12px;
  }

  .page {
    padding: 16px 10px 36px !important;
  }
}

/* Private messages */
.message-nav-link,
.mobile-message-link,
.mobile-message-indicator {
  position: relative;
  gap: 6px;
}

.message-unread-badge {
  min-width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  font-size: 11px;
  font-weight: 950;
  line-height: 1;
}

.message-nav-link.has-unread,
.mobile-message-link.has-unread,
.mobile-message-indicator.has-unread {
  color: #dc2626 !important;
}

.mobile-message-indicator {
  display: none;
}

@media (max-width: 760px) {
  .mobile-message-indicator:not([hidden]) {
    position: fixed;
    right: 14px;
    bottom: 16px;
    z-index: 2600;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border: 1px solid rgba(220, 38, 38, .22);
    border-radius: 999px;
    background: #dc2626;
    color: #fff !important;
    box-shadow: 0 14px 30px rgba(220, 38, 38, .28);
    font-size: 14px;
    font-weight: 950;
    text-decoration: none;
  }

  .mobile-message-indicator .message-unread-badge {
    background: #fff;
    color: #dc2626;
  }
}

.has-new-message .message-unread-badge {
  animation: messagePulse .55s ease-in-out 2;
}

@keyframes messagePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.18); }
}

.message-page-head {
  margin-bottom: 12px;
}

.message-pill,
.message-mini-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  font-weight: 950;
}

.message-pill {
  min-height: 32px;
  padding: 6px 12px;
}

.message-mini-badge {
  min-width: 20px;
  height: 20px;
  margin-left: 6px;
  padding: 0 6px;
  font-size: 11px;
}

.message-compose-form {
  display: grid;
  grid-template-columns: minmax(190px, .32fr) minmax(220px, .38fr) minmax(280px, 1fr) auto;
  gap: 10px;
  align-items: end;
}

.message-compose-form label,
.message-reply-form label {
  display: grid;
  gap: 6px;
  color: #475569;
  font-size: 12px;
  font-weight: 950;
}

.message-compose-body {
  align-self: stretch;
}

.message-compose-body textarea {
  min-height: 92px;
}

.message-table {
  table-layout: auto;
}

.message-table tr.is-unread td {
  background: #fff7ed;
  font-weight: 850;
}

.message-preview {
  max-width: 520px;
  overflow: hidden;
  color: #475569;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-detail-panel {
  max-width: 980px;
  margin: 0 auto;
}

.private-message-list {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.private-message-item {
  width: min(720px, 88%);
  padding: 12px 14px;
  border: 1px solid #dbe4f0;
  border-radius: 14px;
  background: #f8fafc;
}

.private-message-item.is-mine {
  justify-self: end;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.private-message-item.is-admin:not(.is-mine) {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.private-message-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.private-message-meta strong {
  color: #0f172a;
}

.private-message-item p {
  margin: 0;
  overflow-wrap: anywhere;
  line-height: 1.65;
}

.message-reply-form {
  display: grid;
  grid-template-columns: 170px minmax(280px, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #e2e8f0;
}

.admin-message-modal-card {
  width: min(680px, calc(100vw - 36px));
}

.admin-message-form {
  display: grid;
  gap: 12px;
}

.admin-message-form label {
  display: grid;
  gap: 6px;
  color: #475569;
  font-size: 12px;
  font-weight: 950;
}

.admin-message-form textarea {
  min-height: 170px;
}

.admin-message-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.admin-message-status {
  min-width: 0;
  color: #047857;
  font-size: 13px;
  font-weight: 950;
}

.admin-message-status.error {
  color: #b42318;
}

@media (max-width: 720px) {
  .admin-message-footer {
    display: grid;
  }

  .admin-message-footer .button {
    width: 100%;
  }
}

/* CF session monitor */
.cf-session-page {
  margin-bottom: 14px;
}

.cf-kpi-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.cf-kpi-grid article {
  min-width: 0;
  padding: 13px 12px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: #fff;
}

.cf-kpi-grid span,
.cf-kpi-grid small {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.cf-kpi-grid strong {
  display: block;
  margin: 5px 0 2px;
  color: #071327;
  font-size: 23px;
  font-weight: 950;
  line-height: 1.1;
}

.cf-filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 160px 170px auto auto;
  gap: 9px;
  align-items: end;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid #e3eaf3;
  border-radius: 12px;
  background: #f8fafc;
}

.cf-filter-panel label {
  display: grid;
  gap: 5px;
  color: #475569;
  font-size: 12px;
  font-weight: 950;
}

.cf-domain-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cf-domain-card {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: #fff;
}

.cf-domain-card strong,
.cf-domain-card small {
  display: block;
  overflow-wrap: anywhere;
}

.cf-domain-card small {
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}

.cf-domain-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.cf-session-table {
  table-layout: auto;
}

.cf-session-table th {
  white-space: nowrap;
}

.cf-session-table td {
  font-size: 13px;
}

.cf-session-table small {
  display: block;
  max-width: 100%;
  margin-top: 4px;
  overflow-wrap: anywhere;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.cf-health-active td {
  background: #fbfffd;
}

.cf-health-leased td {
  background: #eff6ff;
}

.cf-health-warn td {
  background: #fffbeb;
}

.cf-health-inactive td,
.cf-health-expired td {
  background: #fff7f7;
}

.cf-badge-active {
  background: #def7ec;
  color: #047857;
}

.cf-badge-leased {
  background: #dbeafe;
  color: #1d4ed8;
}

.cf-badge-warn {
  background: #fef3c7;
  color: #92400e;
}

.cf-badge-inactive,
.cf-badge-expired {
  background: #fee2e2;
  color: #b42318;
}

.cf-action-cell {
  display: grid;
  gap: 6px;
  min-width: 96px;
}

.cf-action-cell .button,
.cf-domain-actions .button {
  width: 100%;
}

.collect-status-card {
  display: block;
  margin-top: 12px;
  padding: 14px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #f8fbff;
}

.collect-status-card[data-visible="0"] {
  display: none;
}

.collect-status-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.collect-status-head strong {
  display: block;
  color: #0f172a;
  font-size: 15px;
}

.collect-status-head span {
  display: block;
  margin-top: 4px;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}

.collect-progress-bar {
  height: 9px;
  margin: 12px 0;
  overflow: hidden;
  border-radius: 999px;
  background: #e5edf7;
}

.collect-progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #2563eb;
  transition: width .2s ease;
}

.collect-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.collect-status-grid span {
  padding: 9px 10px;
  border: 1px solid #e3eaf3;
  border-radius: 10px;
  background: #fff;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.collect-status-grid b {
  display: block;
  margin-top: 3px;
  color: #0f172a;
  font-size: 17px;
}

.collect-status-url {
  margin: 10px 0 0;
  color: #64748b;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.collect-api-panel,
.collect-log-panel {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
}

.collect-subhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.collect-subhead strong {
  color: #0f172a;
  font-size: 13px;
}

.collect-subhead small {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.collect-api-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  max-height: 260px;
  overflow: auto;
}

.collect-api-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 8px;
  padding: 9px 10px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #fff;
}

.collect-api-item strong {
  color: #1e293b;
  font-size: 12px;
}

.collect-api-item b {
  color: #0f766e;
  font-size: 15px;
}

.collect-api-item small {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.collect-api-item.is-empty b,
.collect-api-item.is-error b {
  color: #b42318;
}

.collect-api-item.is-empty,
.collect-api-item.is-error {
  border-color: #fecaca;
  background: #fff7f7;
}

.collect-log-box {
  max-height: 360px;
  margin: 0;
  padding: 12px;
  overflow: auto;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #0f172a;
  color: #dbeafe;
  font-family: Consolas, "Courier New", monospace;
  font-size: 12px;
  line-height: 1.55;
  white-space: pre-wrap;
}

@media (max-width: 1180px) {
  .cf-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .cf-domain-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .cf-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cf-filter-panel {
    grid-template-columns: 1fr;
  }

  .cf-session-table {
    min-width: 980px;
  }

  .collect-status-head {
    display: grid;
  }

  .collect-status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collect-api-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .message-compose-form,
  .message-reply-form {
    grid-template-columns: 1fr;
  }

  .message-compose-form .button,
  .message-reply-form .button {
    width: 100%;
  }

  .private-message-item {
    width: 94%;
  }
}

/* Access logs v3 */
.access-page-v3 {
  padding: 2px 0 4px;
}

.access-kpi-grid-v3 {
  grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
}

.access-kpi-grid-v3 article.is-warning {
  border-color: #fecaca;
  background: linear-gradient(180deg, #fff, #fff7f7);
}

.access-kpi-grid-v3 article.is-warning strong {
  color: #b42318;
}

.access-filter-panel-v3 {
  padding: 14px !important;
  border-radius: 16px !important;
}

.access-tabs-v3 {
  grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
}

.access-tab-fake {
  border-color: #fecaca !important;
  background: #fff7f7 !important;
  color: #b42318 !important;
}

.access-tab-fake.active {
  background: #fee2e2 !important;
  box-shadow: 0 0 0 2px rgba(180, 35, 24, .09) !important;
}

.access-tab-suspicious {
  border-color: #fed7aa !important;
  background: #fff7ed !important;
  color: #9a3412 !important;
}

.access-filter-form-v3 {
  grid-template-columns: 170px minmax(260px, 1fr) auto auto !important;
}

.access-insight-grid-v3 {
  align-items: stretch;
}

.access-rank-list-v3 div {
  display: grid;
  gap: 4px;
}

.access-mini-flag {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  margin-left: 5px;
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  vertical-align: middle;
}

.access-mini-flag.fake {
  background: #fee2e2;
  color: #b42318;
}

.access-mini-flag.bot {
  background: #e0f2fe;
  color: #0369a1;
}

.access-panel-v3 {
  border-color: #dbe4f0 !important;
  overflow: visible;
}

.access-table-wrap {
  overflow-x: auto;
}

.access-session-table-v3 {
  min-width: 1180px;
}

.access-session-table-v3 thead th {
  position: sticky;
  top: 0;
  z-index: 1;
}

.access-session-table-v3 tr.is-fake td {
  background: #fffafa;
}

.access-session-table-v3 tr.is-fake:hover td {
  background: #fff4f4;
}

.access-session-table-v3 code {
  display: inline-block;
  padding: 3px 6px;
  border-radius: 7px;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 12px;
}

.access-badge.fake {
  background: #fee2e2;
  color: #b42318;
}

.access-env-cell strong,
.access-hit-cell strong {
  display: block;
  color: #0f172a;
  font-weight: 950;
}

.access-hit-cell .bad {
  color: #b42318 !important;
}

.access-bottom-grid-v3 {
  align-items: start;
}

.login-ua-cell {
  max-width: 420px;
  min-width: 260px;
}

.login-ua-cell strong,
.login-ua-cell small,
.login-ua-cell span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.login-ua-cell strong {
  color: #0f172a;
  font-size: 13px;
  font-weight: 950;
  white-space: nowrap;
}

.login-ua-cell small {
  margin-top: 3px;
  color: #64748b;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.login-ua-cell span {
  margin-top: 5px;
  color: #475569;
  font-family: Consolas, "Courier New", monospace;
  font-size: 11px;
  line-height: 1.45;
  white-space: nowrap;
}

.login-ua-detail {
  margin-top: 6px;
}

.login-ua-detail summary {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid #dbe4f0;
  border-radius: 999px;
  background: #fff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 950;
  cursor: pointer;
  list-style: none;
}

.login-ua-detail summary::-webkit-details-marker {
  display: none;
}

.login-ua-detail code {
  display: block;
  max-width: min(620px, 80vw);
  max-height: 150px;
  margin-top: 7px;
  padding: 10px;
  overflow: auto;
  border: 1px solid #e3eaf3;
  border-radius: 10px;
  background: #0f172a;
  color: #dbeafe;
  font-family: Consolas, "Courier New", monospace;
  font-size: 11px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

@media (max-width: 1180px) {
  .access-kpi-grid-v3 {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  .access-tabs-v3 {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 760px) {
  .access-kpi-grid-v3 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .access-tabs-v3 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .access-filter-form-v3 {
    grid-template-columns: 1fr !important;
  }

  .access-session-table-v3 {
    min-width: 0;
  }

  .login-ua-cell {
    max-width: 100%;
    min-width: 0;
  }
}
