/* 초기화 */
* { box-sizing: border-box; margin:0; padding:0; }
body { font-family: Arial, "Noto Sans KR", sans-serif; background:#f5f6fa; color:#222; }

/* 헤더 */
.site-header { background: linear-gradient(135deg,#2f5cff,#7c4dff); color:white; padding:34px 20px; }
.header-inner { max-width:1100px; margin:0 auto; display:flex; justify-content:space-between; gap:20px; align-items:center; }
.site-header h1 { margin:0 0 8px; font-size:34px; }
.site-header p { margin:0; opacity:0.9; font-size:16px; }
.header-actions { display:flex; gap:10px; align-items:center; }
.header-button { background:white; color:#2f5cff; padding:12px 18px; border-radius:999px; font-weight:bold; box-shadow:0 8px 20px rgba(0,0,0,0.16); border:none; cursor:pointer; font-size:15px; }

/* 햄버거 버튼 */
.menu-open-button { position:fixed; top:18px; left:18px; z-index:50; width:48px; height:48px; border:none; border-radius:16px; background:#fff; cursor:pointer; display:flex; flex-direction:column; justify-content:center; align-items:center; gap:5px; box-shadow:0 8px 22px rgba(20,30,60,0.25); }
.menu-open-button span { width:22px; height:2px; border-radius:999px; background:#2f5cff; display:block; }

/* 오버레이 (투명 처리) */
.menu-overlay { position:fixed; inset:0; background:transparent; z-index:20; opacity:0; pointer-events:none; }
.menu-overlay.hidden { opacity:0; pointer-events:none; }

/* 사이드 메뉴 */
.side-menu { position:fixed; top:0; left:0; width:min(330px,86vw); height:100vh; background:rgba(255,255,255,0.96); backdrop-filter:blur(14px); z-index:100; padding:24px; box-shadow:18px 0 45px rgba(20,30,60,0.24); transform:translateX(-105%); opacity:0; pointer-events:none; transition:transform 0.32s cubic-bezier(0.22,1,0.36,1), opacity 0.22s ease; }
.side-menu:not(.hidden) { transform:translateX(0); opacity:1; pointer-events:auto; }
.side-menu-header { display:flex; align-items:flex-start; justify-content:space-between; margin-bottom:28px; }
.side-menu-header h2 { margin:0; color:#2f5cff; font-size:25px; }
.side-menu-header p { margin:5px 0 0; color:#777; font-size:14px; }
.menu-close-button { width:38px; height:38px; border:none; border-radius:50%; background:#eef1f8; color:#333; font-size:25px; cursor:pointer; }
.menu-close-button:hover { background:#dde3f2; transform:rotate(90deg); }
.side-menu-item { width:100%; border:none; background:transparent; text-align:left; padding:15px 14px; border-radius:16px; font-size:16px; font-weight:bold; cursor:pointer; color:#222; margin-bottom:8px; display:flex; align-items:center; gap:12px; transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease; }
.side-menu-item:hover { background:#edf0ff; color:#2f5cff; transform:translateX(5px); }
.side-menu-icon { width:30px; height:30px; border-radius:11px; background:#eef1f8; color:#2f5cff; display:inline-flex; align-items:center; justify-content:center; flex-shrink:0; }

/* 로그인 모달 */
.auth-content { width:min(440px,100%); padding:30px; border-radius:22px; }
.auth-title { margin-bottom:24px; font-size:26px; text-align:center; color:#222; }
.auth-form { display:grid; grid-template-columns:1fr; gap:10px; }
.auth-label { font-weight:bold; font-size:14px; color:#444; }
.auth-input { width:100%; padding:14px 15px; border-radius:12px; border:1px solid #dde1ee; font-size:15px; background:#fafbff; outline:none; transition:0.2s; }
.auth-input:focus { border-color:#5474ff; background:white; box-shadow:0 0 0 4px rgba(84,116,255,0.14); }
.forgot-password-button { display:block; margin:8px 0 16px auto; border:none; background:transparent; color:#2f7cff; font-weight:bold; font-size:14px; cursor:pointer; }
.forgot-password-button:hover { text-decoration:underline; }
.auth-actions { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:24px; }
.auth-cancel-button, .auth-login-button { border-radius:14px; padding:12px 16px; font-weight:bold; font-size:15px; cursor:pointer; border:none; }
.auth-cancel-button { background:#eef1f8; color:#333; }
.auth-cancel-button:hover { background:#dde3f2; }
.auth-login-button { background:#2f5cff; color:white; }
.auth-login-button:hover { background:#2449d8; }
.auth-divider { display:flex; align-items:center; gap:12px; margin:20px 0 14px; }
.auth-divider span { flex:1; height:1px; background:#e1e5f0; }
.auth-divider p { margin:0; font-size:13px; color:#888; }
.create-account-button { width:100%; border-radius:14px; border:1px solid #dce2f5; background:white; color:#2f5cff; font-size:15px; font-weight:bold; padding:12px 16px; cursor:pointer; }
.create-account-button:hover { background:#f3f5ff; }
/* ===== 응급 복구 CSS: 기본 레이아웃 / 모달 / 폼 복구 ===== */

.hidden {
  display: none !important;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 28px 20px 60px;
}

.hero-section {
  background: white;
  padding: 28px;
  border-radius: 22px;
  box-shadow: 0 10px 26px rgba(20, 30, 60, 0.08);
  margin-bottom: 22px;
}

.hero-section h2 {
  margin: 0 0 10px;
  font-size: 25px;
}

.hero-section p {
  margin: 0;
  line-height: 1.7;
  color: #555;
}

.control-section {
  display: grid;
  grid-template-columns: 1fr 170px 140px;
  gap: 12px;
  margin-bottom: 22px;
}

.control-section input,
.control-section select {
  width: 100%;
  border: 1px solid #dde1ee;
  background: white;
  padding: 13px 14px;
  border-radius: 14px;
  font-size: 15px;
  outline: none;
}

.ad-list-section,
.submit-section {
  background: white;
  padding: 24px;
  border-radius: 22px;
  box-shadow: 0 10px 26px rgba(20, 30, 60, 0.08);
  margin-bottom: 24px;
}

.section-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.section-title-row h2,
.submit-section h2 {
  margin: 0;
}

#adCount {
  background: #edf0ff;
  color: #2f5cff;
  padding: 7px 12px;
  border-radius: 999px;
  font-weight: bold;
  font-size: 14px;
}

.ad-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.empty-message {
  grid-column: 1 / -1;
  text-align: center;
  color: #777;
  padding: 40px 10px;
  border: 1px dashed #ccd2e5;
  border-radius: 18px;
  background: #fafbff;
}

.ad-card {
  position: relative;
  border: 1px solid #e3e6f0;
  border-radius: 18px;
  overflow: hidden;
  background: white;
  cursor: pointer;
  transition: 0.2s;
}

.ad-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 26px rgba(20, 30, 60, 0.12);
}

.ad-image {
  width: 100%;
  height: 150px;
  background: #e9ecf5;
  object-fit: cover;
  display: block;
}

.ad-card-body {
  padding: 16px;
}

.category-badge {
  display: inline-block;
  background: #edf0ff;
  color: #2f5cff;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: bold;
  margin-bottom: 10px;
}

.ad-meta {
  display: flex;
  justify-content: space-between;
  color: #777;
  font-size: 13px;
}

.expire-text {
  margin-top: 12px;
  color: #777;
  font-size: 14px;
}

.submit-guide {
  margin: 8px 0 18px;
  color: #666;
}

.ad-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.ad-form label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-weight: bold;
  color: #333;
}

.ad-form input,
.ad-form select,
.ad-form textarea {
  border: 1px solid #dde1ee;
  padding: 12px 13px;
  border-radius: 13px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
}

.ad-form textarea {
  min-height: 120px;
  resize: vertical;
}

.ad-form label:nth-child(5),
.ad-form button {
  grid-column: 1 / -1;
}

.ad-form button {
  border: none;
  background: #2f5cff;
  color: white;
  padding: 15px;
  border-radius: 15px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
}

.ad-form button:hover {
  background: #2449d8;
}

/* 모달 복구 */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 20, 35, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 200;
}

.modal.hidden {
  display: none !important;
}

.modal-content,
.confirm-content {
  background: white;
  width: min(720px, 100%);
  max-height: 88vh;
  overflow-y: auto;
  border-radius: 22px;
  padding: 24px;
  position: relative;
  box-shadow: 0 16px 40px rgba(20, 30, 60, 0.2);
}

.confirm-content {
  width: min(440px, 100%);
}

.close-button {
  position: absolute;
  right: 18px;
  top: 14px;
  border: none;
  background: #eef1f8;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
}

.modal-image {
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 18px;
  background: #e9ecf5;
}

.modal-title {
  margin: 0 0 10px;
  font-size: 26px;
}

.modal-description {
  line-height: 1.7;
  color: #444;
  white-space: pre-wrap;
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.like-button,
.visit-button {
  border: none;
  border-radius: 13px;
  padding: 12px 15px;
  font-weight: bold;
  cursor: pointer;
  text-decoration: none;
  font-size: 14px;
}

.like-button {
  background: #2f5cff;
  color: white;
}

.visit-button {
  background: #eef1f8;
  color: #222;
}

/* 내 페이지 복구 */
.my-page-content {
  width: min(780px, 100%);
}

.my-page-guide {
  margin: 0 0 22px;
  color: #666;
}

.my-page-section {
  margin-top: 24px;
}

.my-page-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.my-page-empty {
  padding: 22px;
  border: 1px dashed #ccd2e5;
  border-radius: 16px;
  background: #fafbff;
  color: #777;
  text-align: center;
}

/* 로그인 모달 복구 */
.auth-content {
  width: min(440px, 100%);
  padding: 30px;
  border-radius: 22px;
}

.auth-title {
  margin: 0 0 24px;
  font-size: 26px;
  text-align: center;
  color: #222;
}

.auth-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.auth-label {
  font-weight: bold;
  font-size: 14px;
  color: #444;
}

.auth-input {
  width: 100%;
  padding: 14px 15px;
  border-radius: 12px;
  border: 1px solid #dde1ee;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  background: #fafbff;
}

.auth-input:focus {
  border-color: #5474ff;
  background: white;
  box-shadow: 0 0 0 4px rgba(84, 116, 255, 0.14);
}

.forgot-password-button {
  display: block;
  margin: 8px 0 16px auto;
  border: none;
  background: transparent;
  color: #2f7cff;
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
}

.auth-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 24px;
}

.auth-cancel-button,
.auth-login-button {
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: bold;
  font-size: 15px;
  cursor: pointer;
  border: none;
}

.auth-cancel-button {
  background: #eef1f8;
  color: #333;
}

.auth-login-button {
  background: #2f5cff;
  color: white;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0 14px;
}

.auth-divider span {
  flex: 1;
  height: 1px;
  background: #e1e5f0;
}

.auth-divider p {
  margin: 0;
  font-size: 13px;
  color: #888;
}

.create-account-button {
  width: 100%;
  border-radius: 14px;
  border: 1px solid #dce2f5;
  background: white;
  color: #2f5cff;
  font-size: 15px;
  font-weight: bold;
  padding: 12px 16px;
  cursor: pointer;
}

/* 메뉴 복구 */
.menu-overlay {
  position: fixed;
  inset: 0;
  background: transparent;
  z-index: 20;
  opacity: 0;
  pointer-events: none;
}

.side-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: min(330px, 86vw);
  height: 100vh;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  z-index: 100;
  padding: 24px;
  box-shadow: 18px 0 45px rgba(20, 30, 60, 0.24);
  transform: translateX(-105%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.22s ease;
}

.side-menu:not(.hidden) {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.side-menu-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
}

.side-menu-header h2 {
  margin: 0;
  color: #2f5cff;
  font-size: 25px;
}

.side-menu-header p {
  margin: 5px 0 0;
  color: #777;
  font-size: 14px;
}

.menu-close-button {
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: #eef1f8;
  color: #333;
  font-size: 25px;
  cursor: pointer;
}

.side-menu-item {
  width: 100%;
  border: none;
  background: transparent;
  text-align: left;
  padding: 15px 14px;
  border-radius: 16px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  color: #222;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.side-menu-item:hover {
  background: #edf0ff;
  color: #2f5cff;
}

.side-menu-icon {
  width: 30px;
  height: 30px;
  border-radius: 11px;
  background: #eef1f8;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* 모바일 */
@media (max-width: 800px) {
  .site-header {
    padding-top: 78px;
  }

  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .header-actions .header-button {
    text-align: center;
  }

  .control-section {
    grid-template-columns: 1fr;
  }

  .ad-list {
    grid-template-columns: 1fr;
  }

  .ad-form {
    grid-template-columns: 1fr;
  }
}
/* ===== 햄버거 메뉴 슬라이드 복구 ===== */

.side-menu {
  transform: translateX(-105%) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.22s ease !important;
}

.side-menu:not(.hidden) {
  transform: translateX(0) !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}


/* ===== 광고 카드 점 세개 메뉴 UI 복구 ===== */

.card-menu-wrap {
  position: absolute !important;
  top: 10px !important;
  right: 10px !important;
  z-index: 10 !important;
}

.card-menu-button {
  width: 34px !important;
  height: 34px !important;
  border: none !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.94) !important;
  color: #333 !important;
  font-size: 22px !important;
  font-weight: bold !important;
  line-height: 1 !important;
  cursor: pointer !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16) !important;
}

.card-menu-button:hover {
  background: white !important;
}

.card-menu {
  position: absolute !important;
  top: 40px !important;
  right: 0 !important;
  width: 160px !important;
  background: white !important;
  border: 1px solid #e3e6f0 !important;
  border-radius: 14px !important;
  box-shadow: 0 10px 26px rgba(20, 30, 60, 0.18) !important;
  overflow: hidden !important;
  z-index: 999 !important;
}

.card-menu.hidden {
  display: none !important;
}

.card-menu-item {
  width: 100% !important;
  border: none !important;
  background: white !important;
  padding: 12px 14px !important;
  text-align: left !important;
  font-size: 14px !important;
  font-weight: normal !important;
  color: #333 !important;
  cursor: pointer !important;
}

.card-menu-item:hover {
  background: #f5f6fa !important;
}

.card-menu-item.danger {
  color: #d93025 !important;
}

.card-menu-item.danger:hover {
  background: #fff0f0 !important;
}
/* =========================
   모달 버튼 / 내 페이지 UI 복구
========================= */

/* 광고 숨기기 / 추천 취소 모달 */
.confirm-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 20px;
  border-radius: 18px;
  background: white;
  max-width: 400px;
  width: min(90%, 400px);
  margin: 0 auto;
}

.confirm-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.confirm-yes-button,
.confirm-no-button {
  flex: 1;
  padding: 12px 0;
  font-weight: bold;
  font-size: 15px;
  border-radius: 12px;
  cursor: pointer;
}

.confirm-yes-button {
  background: #2f5cff;
  color: white;
  border: none;
}

.confirm-no-button {
  background: #eef1f8;
  color: #333;
  border: none;
}

/* 신고 모달 */
.report-content textarea {
  width: 100%;
  height: 80px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #dde1ee;
  resize: none;
  font-size: 14px;
  font-family: inherit;
}

.report-content .confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* 내 페이지 추천/숨김 목록 */
.my-page-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.my-page-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fff;
  border: 1px solid #e3e6f0;
  border-radius: 14px;
  padding: 12px 14px;
  gap: 12px;
}

.my-page-item-info h4 {
  margin: 0 0 4px 0;
  font-size: 16px;
}

.my-page-item-info p {
  margin: 0;
  font-size: 14px;
  color: #666;
}

.unlike-button,
.unhide-button {
  border: none;
  border-radius: 12px;
  padding: 8px 12px;
  cursor: pointer;
  font-weight: bold;
}

.unlike-button {
  background: #fff0f0;
  color: #d93025;
}

.unhide-button {
  background: #eef1f8;
  color: #333;
}
/* =========================
   모달 버튼 / 신고창 / 내 페이지 UI 복구
========================= */

.confirm-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 20px;
  border-radius: 18px;
  background: white;
  max-width: 420px;
  width: min(90%, 420px);
  margin: 0 auto;
}

.confirm-content h3 {
  margin: 0;
  font-size: 21px;
}

.confirm-content p {
  margin: 0;
  color: #666;
  line-height: 1.6;
}

.confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}

.confirm-no-button,
.confirm-yes-button {
  border: none;
  border-radius: 13px;
  padding: 12px 16px;
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
}

.confirm-no-button {
  background: #eef1f8;
  color: #333;
}

.confirm-no-button:hover {
  background: #dde3f2;
}

.confirm-yes-button {
  background: #2f5cff;
  color: white;
}

.confirm-yes-button:hover {
  background: #2449d8;
}

.report-content {
  width: min(480px, 100%);
}

.report-reason-input {
  width: 100%;
  min-height: 120px;
  margin-top: 4px;
  border: 1px solid #dde1ee;
  border-radius: 14px;
  padding: 13px;
  font-size: 15px;
  font-family: inherit;
  resize: vertical;
  outline: none;
}

.report-reason-input:focus {
  border-color: #5474ff;
  box-shadow: 0 0 0 3px rgba(84, 116, 255, 0.15);
}

.my-page-section {
  margin-top: 24px;
}

.my-page-section h3 {
  margin: 0 0 12px;
  font-size: 20px;
}

.my-page-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.my-page-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  border: 1px solid #e3e6f0;
  border-radius: 16px;
  padding: 14px;
  background: white;
}

.my-page-item-info {
  min-width: 0;
}

.my-page-item-info h4 {
  margin: 0 0 6px;
  font-size: 16px;
}

.my-page-item-info p {
  margin: 0;
  color: #666;
  font-size: 14px;
}

.unlike-button,
.unhide-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
}

.unlike-button {
  background: #fff0f0;
  color: #d93025;
}

.unlike-button:hover {
  background: #ffe0e0;
}

.unhide-button {
  background: #eef1f8;
  color: #333;
}

.unhide-button:hover {
  background: #dde3f2;
}

.my-page-empty {
  padding: 22px;
  border: 1px dashed #ccd2e5;
  border-radius: 16px;
  background: #fafbff;
  color: #777;
  text-align: center;
}

@media (max-width: 800px) {
  .my-page-item {
    flex-direction: column;
    align-items: stretch;
  }

  .unlike-button,
  .unhide-button {
    width: 100%;
  }
}
/* =========================
   관리자 상태 / 로그아웃 버튼 UI 복구
========================= */

.admin-status {
  margin-top: 18px;
  padding: 13px 14px;
  border-radius: 16px;
  background: linear-gradient(135deg, #edf0ff, #f6f3ff);
  color: #2f5cff;
  font-size: 14px;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: inset 0 0 0 1px rgba(84, 116, 255, 0.12);
}

.admin-status::before {
  content: "✓";
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #2f5cff;
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  flex-shrink: 0;
}

.logout-button {
  width: 100%;
  margin-top: 10px;
  border: none;
  border-radius: 16px;
  background: #fff0f0;
  color: #d93025;
  padding: 14px;
  font-size: 15px;
  font-weight: bold;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
}

.logout-button:hover {
  background: #ffe0e0;
  transform: translateX(4px);
}
/* =========================
   로그인 실패 UI
========================= */

.auth-error-message {
  margin: 2px 0 0;
  padding: 11px 12px;
  border-radius: 12px;
  background: #fff0f0;
  color: #d93025;
  font-size: 14px;
  font-weight: bold;
  line-height: 1.5;
}

.auth-input.auth-input-error {
  border-color: #d93025 !important;
  background: #fff8f8 !important;
  box-shadow: 0 0 0 4px rgba(217, 48, 37, 0.12) !important;
}
/* =========================
   햄버거 메뉴 슬라이드 애니메이션 복구
========================= */

.side-menu {
  display: block !important;
  transform: translateX(-105%) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  transition:
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.22s ease !important;
}

.side-menu:not(.hidden) {
  transform: translateX(0) !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.side-menu.hidden {
  display: block !important;
  transform: translateX(-105%) !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
/* =========================
   햄버거 메뉴 닫힘 반응 속도 조정
========================= */

.side-menu {
  transition:
    transform 0.22s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.16s ease !important;
}
/* =========================
   광고 등록 성공 알림 UI
========================= */

.success-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 500;
  display: flex;
  align-items: center;
  gap: 13px;
  width: min(360px, calc(100vw - 32px));
  padding: 16px 18px;
  border-radius: 18px;
  background: white;
  box-shadow: 0 16px 40px rgba(20, 30, 60, 0.22);
  border: 1px solid #e3e6f0;
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.success-toast:not(.hidden) {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.success-toast-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #2f5cff;
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  flex-shrink: 0;
}

.success-toast-text strong {
  display: block;
  font-size: 15px;
  color: #222;
  margin-bottom: 3px;
}

.success-toast-text p {
  margin: 0;
  font-size: 14px;
  color: #666;
}

@media (max-width: 800px) {
  .success-toast {
    left: 16px;
    right: 16px;
    bottom: 18px;
    width: auto;
  }
}
/* =========================
   관리자 광고 삭제 버튼 UI
========================= */

.danger-confirm-button {
  background: #d93025 !important;
  color: white !important;
}

.danger-confirm-button:hover {
  background: #b3261e !important;
}
.admin-delete-menu-item {
  border-top: 1px solid #f0d0d0 !important;
  color: #d93025 !important;
  font-weight: bold !important;
}
/* =========================
   관리자 신고 관리 UI
========================= */

.admin-menu-button {
  width: 100%;
  margin-top: 10px;
  border: none;
  border-radius: 16px;
  background: #edf0ff;
  color: #2f5cff;
  padding: 14px;
  font-size: 15px;
  font-weight: bold;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
}

.admin-menu-button:hover {
  background: #dde3ff;
  transform: translateX(4px);
}

.report-manage-content {
  width: min(780px, 100%);
}

.report-manage-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
}

.report-manage-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  border: 1px solid #e3e6f0;
  border-radius: 16px;
  padding: 14px;
  background: white;
}

.report-manage-info {
  min-width: 0;
}

.report-manage-info h4 {
  margin: 0 0 8px;
  font-size: 16px;
}

.report-reason-text {
  margin: 0 0 6px;
  color: #444;
  line-height: 1.5;
  white-space: pre-wrap;
}

.report-date-text {
  margin: 0;
  color: #888;
  font-size: 13px;
}

.report-delete-ad-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  background: #fff0f0;
  color: #d93025;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
}

.report-delete-ad-button:hover {
  background: #ffe0e0;
}

@media (max-width: 800px) {
  .report-manage-item {
    flex-direction: column;
    align-items: stretch;
  }

  .report-delete-ad-button {
    width: 100%;
  }
}
/* =========================
   신고 관리 광고 확인 UI
========================= */

.report-ad-summary {
  margin: 0 0 8px;
  color: #666;
  font-size: 14px;
  line-height: 1.5;
}

.report-manage-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}

.report-preview-ad-button,
.report-delete-ad-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.report-preview-ad-button {
  background: #edf0ff;
  color: #2f5cff;
}

.report-preview-ad-button:hover {
  background: #dde3ff;
}

.report-delete-ad-button {
  background: #fff0f0;
  color: #d93025;
}

.report-delete-ad-button:hover {
  background: #ffe0e0;
}

@media (max-width: 800px) {
  .report-manage-actions {
    flex-direction: column;
    width: 100%;
  }

  .report-preview-ad-button,
  .report-delete-ad-button {
    width: 100%;
  }
}
/* =========================
   신고 관리 hover 미리보기 + 자세히 보기 버튼
========================= */

.report-manage-item {
  position: relative;
}

.report-hover-preview {
  position: absolute;
  top: 50%;
  right: 150px;
  width: 270px;
  transform: translateY(-50%) translateX(10px);
  opacity: 0;
  pointer-events: none;
  z-index: 50;
  background: white;
  border: 1px solid #e3e6f0;
  border-radius: 16px;
  padding: 14px;
  box-shadow: 0 14px 34px rgba(20, 30, 60, 0.18);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.report-hover-preview strong {
  display: block;
  margin-bottom: 7px;
  font-size: 15px;
  color: #222;
}

.report-hover-preview p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

.report-hover-category {
  color: #2f5cff !important;
  font-weight: bold;
  margin-bottom: 6px !important;
}

.report-hover-summary {
  color: #555;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.report-manage-item:hover .report-hover-preview {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

.report-manage-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}

.report-preview-ad-button,
.report-delete-ad-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.report-preview-ad-button {
  background: #edf0ff;
  color: #2f5cff;
}

.report-preview-ad-button:hover {
  background: #dde3ff;
}

.report-delete-ad-button {
  background: #fff0f0;
  color: #d93025;
}

.report-delete-ad-button:hover {
  background: #ffe0e0;
}

@media (max-width: 800px) {
  .report-hover-preview {
    display: none;
  }

  .report-manage-actions {
    width: 100%;
  }

  .report-preview-ad-button,
  .report-delete-ad-button {
    width: 100%;
  }
}
/* =========================
   댓글 UI
========================= */

.comment-section {
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid #e3e6f0;
}

.comment-section h3 {
  margin: 0 0 14px;
  font-size: 20px;
}

.comment-form {
  display: grid;
  grid-template-columns: 150px 1fr auto;
  gap: 10px;
  margin-bottom: 18px;
}

.comment-form input,
.comment-form textarea {
  border: 1px solid #dde1ee;
  border-radius: 13px;
  padding: 12px 13px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  background: #fafbff;
}

.comment-form textarea {
  min-height: 44px;
  max-height: 120px;
  resize: vertical;
}

.comment-form input:focus,
.comment-form textarea:focus {
  border-color: #5474ff;
  background: white;
  box-shadow: 0 0 0 3px rgba(84, 116, 255, 0.13);
}

.comment-form button {
  border: none;
  border-radius: 13px;
  background: #2f5cff;
  color: white;
  padding: 0 16px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
}

.comment-form button:hover {
  background: #2449d8;
}

.comment-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.comment-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  border: 1px solid #e3e6f0;
  border-radius: 15px;
  padding: 13px;
  background: #fafbff;
}

.comment-main {
  min-width: 0;
}

.comment-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.comment-header strong {
  color: #222;
  font-size: 14px;
}

.comment-header span {
  color: #888;
  font-size: 12px;
}

.comment-item p {
  margin: 0;
  color: #444;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

.comment-empty {
  padding: 18px;
  border: 1px dashed #ccd2e5;
  border-radius: 15px;
  background: #fafbff;
  color: #777;
  text-align: center;
  font-size: 14px;
}

.comment-delete-button {
  border: none;
  border-radius: 11px;
  background: #fff0f0;
  color: #d93025;
  padding: 8px 11px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
}

.comment-delete-button:hover {
  background: #ffe0e0;
}

@media (max-width: 800px) {
  .comment-form {
    grid-template-columns: 1fr;
  }

  .comment-form button {
    padding: 12px 16px;
  }

  .comment-item {
    flex-direction: column;
  }

  .comment-delete-button {
    width: 100%;
  }
}

/* =========================
   광고 카드 추천 / 조회 / 댓글 위치 조정
========================= */

.ad-meta {
  display: grid !important;
  grid-template-columns: 1fr auto !important;
  grid-template-rows: auto auto !important;
  column-gap: 12px !important;
  row-gap: 5px !important;
  align-items: start !important;
}

.ad-meta > span:nth-child(1) {
  grid-column: 1 !important;
  grid-row: 1 !important;
  justify-self: start !important;
}

.ad-meta > span:nth-child(2) {
  grid-column: 2 !important;
  grid-row: 1 !important;
  justify-self: end !important;
}

.ad-meta > span:nth-child(3) {
  grid-column: 2 !important;
  grid-row: 2 !important;
  justify-self: end !important;
}
/* =========================
   로그인 / 회원가입 모드 UI
========================= */

.auth-guide-text {
  margin: -12px 0 20px;
  color: #666;
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}
/* =========================
   로그인 / 회원가입 성공 메시지 UI
========================= */

.auth-success-message {
  margin: 2px 0 0;
  padding: 11px 12px;
  border-radius: 12px;
  background: #eefaf1;
  color: #188038;
  font-size: 14px;
  font-weight: bold;
  line-height: 1.5;
}
/* =========================
   내 프로필 UI
========================= */

.my-profile-card {
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid #e3e6f0;
  border-radius: 18px;
  padding: 16px;
  background: #fafbff;
}

.my-profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 24px;
  flex-shrink: 0;
  overflow: hidden;
}

.my-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.my-profile-info {
  min-width: 0;
  flex: 1;
}

.my-profile-info strong {
  display: block;
  font-size: 18px;
  margin-bottom: 5px;
}

.my-profile-info p {
  margin: 0;
  color: #666;
  font-size: 14px;
}

.my-profile-bio {
  margin-top: 8px !important;
  color: #444 !important;
  line-height: 1.5;
}

.my-profile-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}

.profile-edit-button,
.account-delete-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.profile-edit-button {
  background: #edf0ff;
  color: #2f5cff;
}

.profile-edit-button:hover {
  background: #dde3ff;
}

.account-delete-button {
  background: #fff0f0;
  color: #d93025;
}

.account-delete-button:hover {
  background: #ffe0e0;
}

.admin-account-guide {
  max-width: 170px;
  margin: 0;
  color: #888;
  font-size: 12px;
  line-height: 1.5;
}

@media (max-width: 800px) {
  .my-profile-card {
    flex-direction: column;
    align-items: stretch;
  }

  .my-profile-avatar {
    align-self: center;
  }

  .my-profile-actions {
    width: 100%;
  }

  .profile-edit-button,
  .account-delete-button {
    width: 100%;
  }

  .admin-account-guide {
    max-width: none;
    text-align: center;
  }
}
/* =========================
   계정 삭제 확인 모달 UI
========================= */

.account-delete-content {
  width: min(460px, 100%);
}

.account-delete-content .auth-label {
  margin-top: 4px;
}

.account-delete-content .auth-input {
  margin-top: -6px;
}
/* =========================
   내 프로필 수정 UI
========================= */

.my-profile-edit-card {
  border: 1px solid #e3e6f0;
  border-radius: 18px;
  padding: 16px;
  background: #fafbff;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.profile-bio-input {
  width: 100%;
  min-height: 82px;
  border: 1px solid #dde1ee;
  border-radius: 13px;
  padding: 12px 13px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  background: white;
  resize: vertical;
}

.profile-bio-input:focus {
  border-color: #5474ff;
  box-shadow: 0 0 0 3px rgba(84, 116, 255, 0.13);
}

.my-profile-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}

@media (max-width: 800px) {
  .my-profile-edit-actions {
    flex-direction: column;
  }

  .my-profile-edit-actions button {
    width: 100%;
  }
}
/* =========================
   프로필 이미지 업로드 UI
========================= */

.profile-avatar-edit-preview {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  font-size: 30px;
  font-weight: bold;
  overflow: hidden;
  border: 1px solid #dce2f5;
}

.profile-avatar-edit-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-avatar-input {
  border: 1px solid #dde1ee;
  border-radius: 13px;
  padding: 11px;
  background: white;
  font-family: inherit;
}

.profile-image-guide {
  margin: -4px 0 4px;
  color: #777;
  font-size: 13px;
  line-height: 1.5;
}
/* =========================
   프로필 이미지 파일 선택 버튼 UI
========================= */

.profile-file-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.profile-avatar-input {
  display: none;
}

.profile-file-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 13px;
  background: #2f5cff;
  color: white;
  padding: 11px 15px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(47, 92, 255, 0.22);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.profile-file-button:hover {
  background: #2449d8;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(47, 92, 255, 0.28);
}

.profile-file-name {
  color: #666;
  font-size: 13px;
  max-width: 230px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 800px) {
  .profile-file-row {
    flex-direction: column;
    align-items: stretch;
  }

  .profile-file-button {
    width: 100%;
  }

  .profile-file-name {
    max-width: 100%;
    text-align: center;
  }
}
/* =========================
   내가 게시한 광고 UI
========================= */

.my-posted-ad-item {
  align-items: center;
}

.my-posted-ad-status {
  margin-top: 4px !important;
  color: #777 !important;
  font-size: 13px !important;
}

.my-posted-ad-view-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  background: #edf0ff;
  color: #2f5cff;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.my-posted-ad-view-button:hover {
  background: #dde3ff;
}

@media (max-width: 800px) {
  .my-posted-ad-item {
    flex-direction: column;
    align-items: stretch;
  }

  .my-posted-ad-view-button {
    width: 100%;
  }
}
/* =========================
   내가 게시한 광고 관리 버튼
========================= */

.my-posted-ad-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.my-posted-ad-delete-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  background: #fff0f0;
  color: #d93025;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.my-posted-ad-delete-button:hover {
  background: #ffe0e0;
}

@media (max-width: 800px) {
  .my-posted-ad-actions {
    width: 100%;
    flex-direction: column;
  }

  .my-posted-ad-actions button {
    width: 100%;
  }
}
/* =========================
   광고 이미지 업로드 UI
========================= */

.ad-image-upload-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.ad-image-file-input {
  display: none;
}

.ad-image-file-button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  border: none;
  border-radius: 13px;
  background: #2f5cff;
  color: white;
  padding: 11px 15px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(47, 92, 255, 0.22);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.ad-image-file-button:hover {
  background: #2449d8;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(47, 92, 255, 0.28);
}

.ad-image-file-name {
  color: #666;
  font-size: 13px;
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ad-image-guide {
  margin: 6px 0 0;
  color: #777;
  font-size: 13px;
  line-height: 1.5;
}

@media (max-width: 800px) {
  .ad-image-upload-row {
    flex-direction: column;
    align-items: stretch;
  }

  .ad-image-file-button {
    width: 100% !important;
  }

  .ad-image-file-name {
    max-width: 100%;
    text-align: center;
  }
}
.ad-image-file-button {
  color: white !important;
}
/* =========================
   광고 게시자 표시 UI
========================= */

.ad-author-row {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 4px 0 12px;
  padding: 9px;
  border-radius: 14px;
  background: #fafbff;
  border: 1px solid #edf0f8;
}

.ad-author-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 14px;
  font-weight: bold;
  flex-shrink: 0;
}

.ad-author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ad-author-info {
  min-width: 0;
}

.ad-author-info strong {
  display: block;
  font-size: 13px;
  color: #333;
  line-height: 1.2;
}

.ad-author-info p {
  margin: 2px 0 0;
  color: #777;
  font-size: 12px;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.modal-author-box {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0 16px;
  padding: 13px;
  border-radius: 16px;
  background: #fafbff;
  border: 1px solid #e8ecf7;
}

.modal-author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 18px;
  font-weight: bold;
  flex-shrink: 0;
}

.modal-author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-author-info {
  min-width: 0;
}

.modal-author-info strong {
  display: block;
  font-size: 16px;
  color: #222;
  margin-bottom: 3px;
}

.modal-author-info p {
  margin: 0;
  color: #666;
  font-size: 14px;
  line-height: 1.5;
}
/* =========================
   광고 게시자 표시 UI
========================= */

.ad-author-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 4px 0 12px;
  padding: 7px 10px;
  border-radius: 999px;
  background: #fafbff;
  border: 1px solid #edf0f8;
  max-width: 100%;
}

.ad-author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 13px;
  font-weight: bold;
  flex-shrink: 0;
}

.ad-author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ad-author-row strong {
  font-size: 13px;
  color: #333;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.modal-author-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0 16px;
  padding: 9px 12px;
  border-radius: 999px;
  background: #fafbff;
  border: 1px solid #e8ecf7;
}

.modal-author-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 15px;
  font-weight: bold;
  flex-shrink: 0;
}

.modal-author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-author-box strong {
  font-size: 15px;
  color: #222;
}
/* =========================
   광고 카드 상단 정보 정렬 수정
========================= */

.ad-card-top-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 4px 0 12px;
  flex-wrap: wrap;
}

.ad-card-top-row .category-badge {
  margin-bottom: 0;
}

.ad-author-row {
  margin: 0;
}
/* =========================
   광고 카드 카테고리 / 게시자 y축 정렬 보정
========================= */

.ad-card-top-row {
  display: flex;
  align-items: center !important;
  gap: 8px;
  margin: 4px 0 12px;
  flex-wrap: wrap;
}

.ad-card-top-row .category-badge {
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0 !important;
  padding: 0 12px;
  line-height: 1;
}

.ad-author-row {
  height: 36px;
  display: inline-flex;
  align-items: center !important;
  margin: 0 !important;
  padding: 4px 10px;
  line-height: 1;
}

.ad-author-avatar {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ad-author-row strong {
  display: inline-flex;
  align-items: center;
  height: 100%;
  line-height: 1;
}
.ad-card-body > p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.45;
}
/* =========================
   광고 짧은 소개 말줄임 처리
========================= */

.ad-card-body > p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;

  overflow: hidden;
  text-overflow: ellipsis;

  line-height: 1.45;
  min-height: calc(1.45em * 2);

  color: #666;
}
/* =========================
   로그인 상태 이메일 입력칸 잠금
========================= */

.locked-email-input {
  background: #eef1f8 !important;
  color: #666 !important;
  cursor: not-allowed !important;
}
/* =========================
   게시자 클릭 / 공개 프로필 모달
========================= */

.ad-author-button,
.modal-author-button {
  border: 1px solid #edf0f8;
  font-family: inherit;
  cursor: default;
}

.ad-author-button.clickable,
.modal-author-button.clickable {
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.ad-author-button.clickable:hover,
.modal-author-button.clickable:hover {
  transform: translateY(-2px);
  background: #f3f5ff;
  box-shadow: 0 8px 18px rgba(47, 92, 255, 0.12);
}

.ad-author-button.anonymous,
.modal-author-button.anonymous {
  cursor: default;
}

.public-profile-content {
  width: min(620px, 100%);
}

.public-profile-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 0 20px;
  border-bottom: 1px solid #e8ecf7;
}

.public-profile-avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: #edf0ff;
  color: #2f5cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 28px;
  font-weight: bold;
  flex-shrink: 0;
}

.public-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.public-profile-info {
  min-width: 0;
}

.public-profile-info h2 {
  margin: 0 0 6px;
  font-size: 24px;
}

.public-profile-info p {
  margin: 0;
  color: #666;
  font-size: 14px;
}

.public-profile-section {
  margin-top: 20px;
}

.public-profile-section h3 {
  margin: 0 0 12px;
  font-size: 19px;
}

.public-profile-ad-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.public-profile-ad-item {
  width: 100%;
  border: 1px solid #e3e6f0;
  background: white;
  border-radius: 14px;
  padding: 13px 14px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.18s ease, transform 0.18s ease;
}

.public-profile-ad-item:hover {
  background: #fafbff;
  transform: translateY(-1px);
}

.public-profile-ad-item strong {
  display: block;
  font-size: 15px;
  color: #222;
  margin-bottom: 4px;
}

.public-profile-ad-item p {
  margin: 0;
  color: #666;
  font-size: 13px;
}

@media (max-width: 800px) {
  .public-profile-header {
    flex-direction: column;
    text-align: center;
  }
}
.public-profile-bio {
  margin: 4px 0 6px !important;
  color: #444 !important;
  font-size: 14px !important;
  line-height: 1.5 !important;
}
/* =========================
   내 광고 수정 모달
========================= */

.edit-my-ad-content {
  width: min(620px, 100%);
}

.edit-my-ad-form {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.edit-my-ad-form label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-weight: bold;
  color: #333;
}

.edit-my-ad-form input,
.edit-my-ad-form select,
.edit-my-ad-form textarea {
  border: 1px solid #dde1ee;
  padding: 12px 13px;
  border-radius: 13px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
}

.edit-my-ad-form textarea {
  min-height: 150px;
  resize: vertical;
}

.edit-my-ad-form input:focus,
.edit-my-ad-form select:focus,
.edit-my-ad-form textarea:focus {
  border-color: #5474ff;
  box-shadow: 0 0 0 3px rgba(84, 116, 255, 0.13);
}

.my-posted-ad-edit-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  background: #edf0ff;
  color: #2f5cff;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.my-posted-ad-edit-button:hover {
  background: #dde3ff;
}
.card-menu-divider {
  height: 1px;
  background: #eef1f8;
  margin: 4px 0;
}
/* =========================
   오늘의 고정 홍보
========================= */

.sponsored-section {
  background: white;
  padding: 22px 24px;
  border-radius: 22px;
  box-shadow: 0 10px 26px rgba(20, 30, 60, 0.08);
  margin-bottom: 22px;
}

.sponsored-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.sponsored-title-row h2 {
  margin: 0 0 5px;
  font-size: 22px;
}

.sponsored-title-row p {
  margin: 0;
  color: #666;
  font-size: 14px;
}

.sponsor-inquiry-button {
  border: none;
  border-radius: 999px;
  background: #edf0ff;
  color: #2f5cff;
  padding: 10px 14px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.sponsor-inquiry-button:hover {
  background: #dde3ff;
}

.sponsored-ad-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(142px, 1fr));
  gap: 12px;
}

.sponsored-ad-card {
  border: 1px solid #e3e6f0;
  background: #fff;
  border-radius: 17px;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.sponsored-ad-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(20, 30, 60, 0.13);
}

.sponsored-image-wrap {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #e9ecf5;
}

.sponsored-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sponsored-fixed-badge {
  position: absolute;
  left: 9px;
  top: 9px;
  border-radius: 999px;
  padding: 4px 8px;
  background: rgba(47, 92, 255, 0.92);
  color: white;
  font-size: 12px;
  font-weight: bold;
}

.sponsored-card-body {
  padding: 11px;
}

.sponsored-category {
  display: inline-block;
  max-width: 100%;
  margin-bottom: 7px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #edf0ff;
  color: #2f5cff;
  font-size: 12px;
  font-weight: bold;
}

.sponsored-card-body strong {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;

  overflow: hidden;
  text-overflow: ellipsis;

  color: #222;
  font-size: 14px;
  line-height: 1.35;
}

.sponsored-empty-card {
  grid-column: 1 / -1;
  padding: 18px;
  border: 1px dashed #ccd2e5;
  border-radius: 16px;
  background: #fafbff;
  color: #666;
}

.sponsored-empty-card strong {
  display: block;
  margin-bottom: 5px;
  color: #333;
}

.sponsored-empty-card p {
  margin: 0;
  font-size: 14px;
}

@media (max-width: 800px) {
  .sponsored-title-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .sponsor-inquiry-button {
    width: 100%;
  }

  .sponsored-ad-list {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    padding-bottom: 4px;
  }

  .sponsored-ad-card {
    min-width: 142px;
    max-width: 142px;
  }
}
.locked-comment-nickname {
  background: #eef1f8 !important;
  color: #555 !important;
  cursor: not-allowed !important;
}
/* =========================
   로그인 사용자 댓글 체크 표시
========================= */

.comment-nickname {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.verified-comment-badge {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #2f5cff;
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: bold;
  line-height: 1;
}
.verified-comment-badge {
  background: #7fa2ff !important;
  color: white !important;
}
/* =========================
   토큰 잔액 표시
========================= */

.token-balance-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  margin-top: 8px;
  padding: 8px 11px;
  border-radius: 999px;
  background: #edf0ff;
  color: #2f5cff;
  font-size: 13px;
  font-weight: bold;
}

.token-balance-box strong {
  color: #1f46d8;
  font-size: 14px;
}
/* =========================
   토큰 잔액 표시 개선
========================= */
.token-balance-box {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #edf0ff; /* 배경은 연한 파랑 */
  font-size: 14px;
  font-family: inherit; /* 다른 텍스트와 같은 폰트로 통일 */
  color: #2f5cff; /* 전체 텍스트 색 동일하게 */
  font-weight: 500; /* 전체 글자 굵기 통일 */
}

.token-balance-box strong {
  font-weight: 700; /* 숫자만 강조 */
  font-size: 14px; /* 숫자 크기 전체와 동일 */
  color: #2f5cff; /* 숫자 색상 통일 */
}
/* =========================
   상단 고정 토큰 버튼 / 구매 모달
========================= */

.floating-token-button {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 60;
  border: none;
  border-radius: 999px;
  padding: 10px 14px;
  background: white;
  color: #2f5cff;
  box-shadow: 0 8px 22px rgba(20, 30, 60, 0.18);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.floating-token-button:hover {
  transform: translateY(-2px);
  background: #f7f8ff;
  box-shadow: 0 10px 26px rgba(20, 30, 60, 0.22);
}

.floating-token-button span,
.floating-token-button strong {
  color: #2f5cff;
  font-size: 14px;
  line-height: 1;
}

.floating-token-button strong {
  font-weight: 800;
}

.token-purchase-content {
  position: relative;
  width: min(440px, 100%);
}

.token-price-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 0;
}

.token-price-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #e3e6f0;
  border-radius: 14px;
  padding: 13px 14px;
  background: #fafbff;
}

.token-price-item strong {
  color: #2f5cff;
}

.token-price-item span {
  color: #333;
  font-weight: bold;
}

.token-purchase-guide {
  margin-top: 8px !important;
  color: #777 !important;
  font-size: 14px !important;
}

@media (max-width: 800px) {
  .floating-token-button {
    top: 18px;
    right: 14px;
    padding: 9px 12px;
  }

  .floating-token-button span,
  .floating-token-button strong {
    font-size: 13px;
  }
}
/* =========================
   토큰 사용 버튼
========================= */

.my-posted-ad-extend-button,
.my-posted-ad-sponsor-button {
  border: none;
  border-radius: 12px;
  padding: 10px 13px;
  background: #edf0ff;
  color: #2f5cff;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
}

.my-posted-ad-extend-button:hover,
.my-posted-ad-sponsor-button:hover {
  background: #dde3ff;
}

.my-posted-ad-sponsor-button:disabled {
  background: #eeeeee;
  color: #888;
  cursor: not-allowed;
}
/* =========================
   공통 안내 모달
========================= */

.notice-modal-content {
  width: min(420px, 100%);
  text-align: center;
}

.notice-modal-content h3 {
  margin: 0 0 10px;
  font-size: 22px;
  color: #222;
}

.notice-modal-content p {
  white-space: pre-line;
  margin: 0 0 18px;
  color: #555;
  line-height: 1.6;
  font-size: 15px;
}
/* =========================
   토큰 실제 결제 버튼
========================= */

.token-buy-button {
  width: 100%;
  border: 1px solid #e3e6f0;
  font-family: inherit;
  cursor: pointer;
  appearance: none;
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.token-buy-button:hover {
  background: #f1f4ff;
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(47, 92, 255, 0.12);
}

.token-buy-button:active {
  transform: translateY(0);
}

/* =========================
   결제 결과 페이지
========================= */

.payment-result-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 20px;
  background: #f5f6fa;
}

.payment-result-card {
  width: min(460px, 100%);
  padding: 30px;
  border-radius: 22px;
  background: white;
  box-shadow: 0 12px 30px rgba(20, 30, 60, 0.12);
  text-align: center;
}

.payment-result-card h1 {
  margin: 0 0 12px;
  font-size: 25px;
  color: #222;
}

.payment-result-card p {
  margin: 0 0 22px;
  color: #555;
  line-height: 1.7;
}

.payment-home-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: #2f5cff;
  color: white;
  font-weight: bold;
  text-decoration: none;
}
/* =========================
   푸터 / 정책 모달
========================= */

.site-footer {
  max-width: 1100px;
  margin: -24px auto 50px;
  padding: 0 20px;
  display: flex;
  justify-content: center;
  gap: 14px;
}

.footer-link-button {
  border: none;
  background: transparent;
  color: #666;
  font-size: 14px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-link-button:hover {
  color: #2f5cff;
}

.policy-content {
  width: min(620px, 100%);
}

.policy-text {
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: #444;
  line-height: 1.7;
}

.policy-text h3 {
  margin: 12px 0 0;
  font-size: 17px;
  color: #222;
}

.policy-text p {
  margin: 0;
}
.inline-policy-button {
  border: none;
  background: transparent;
  color: #2f5cff;
  font: inherit;
  font-weight: bold;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.inline-policy-button:hover {
  color: #2449d8;
}
#refundPolicyModal {
  z-index: 300;
}
.site-footer {
  max-width: 1100px;
  margin: -24px auto 50px;
  padding: 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
/* =========================
   모바일 보유 토큰 버튼 위치 보정
========================= */

@media (max-width: 800px) {
  .floating-token-button {
    top: auto !important;
    right: 16px !important;
    bottom: calc(18px + env(safe-area-inset-bottom)) !important;
    z-index: 700 !important;
    padding: 10px 13px !important;
    border-radius: 999px !important;
    box-shadow: 0 10px 26px rgba(20, 30, 60, 0.24) !important;
  }

  .floating-token-button span,
  .floating-token-button strong {
    font-size: 13px !important;
  }
}
/* =========================
   모바일 보유 토큰 버튼 우측 상단 배치
========================= */

@media (max-width: 800px) {
  .floating-token-button:not(.hidden) {
    display: flex !important;
    position: fixed !important;

    top: calc(14px + env(safe-area-inset-top)) !important;
    right: 14px !important;
    bottom: auto !important;
    left: auto !important;
    transform: none !important;

    z-index: 99999 !important;

    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;

    width: auto !important;
    max-width: calc(100vw - 80px) !important;
    min-height: 38px !important;

    padding: 8px 11px !important;
    border-radius: 999px !important;

    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;

    box-shadow: 0 8px 20px rgba(20, 30, 60, 0.22) !important;
  }

  .floating-token-button.hidden {
    display: none !important;
  }

  .floating-token-button span,
  .floating-token-button strong {
    font-size: 12px !important;
    white-space: nowrap !important;
  }
}
/* =========================
   헤더 로고
========================= */

.header-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header-logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 18px;
}

@media (max-width: 800px) {
  .header-brand {
    gap: 12px;
  }

  .header-logo {
    width: 52px;
    height: 52px;
    border-radius: 14px;
  }
}
/* =========================
   모달 열렸을 때 보유 토큰 버튼 뒤로 보내기
========================= */

/* 모든 모달은 보유토큰 버튼보다 위에 오도록 고정 */
.modal {
  z-index: 1000 !important;
}

.modal-content,
.confirm-content {
  position: relative;
  z-index: 1001 !important;
}

.close-button {
  z-index: 1002 !important;
}

/* 기본 보유토큰 버튼은 평소처럼 보이게 */
.floating-token-button {
  z-index: 60 !important;
}

/* 모달이 하나라도 열려 있으면 보유토큰 버튼을 뒤로 보냄 */
body:has(.modal:not(.hidden)) .floating-token-button:not(.hidden) {
  z-index: 50 !important;
  pointer-events: none !important;
}
/* =========================================================
   여기부터 시작
========================================================= */
