/* assets/css/style.css — SmartPost global styles */
/* Primary colour: #3B5BDB (blue) */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --blue:   #3B5BDB;
  --blue-l: #4263eb;
  --blue-bg:#eef2ff;
  --green:  #37B24D;
  --red:    #e03131;
  --orange: #F59F00;
  --pink:   #E64980;
  --bg:     #f5f6fa;
  --card:   #ffffff;
  --text:   #212529;
  --muted:  #868e96;
  --border: #dee2e6;
  --radius: 12px;
  --shadow: 0 2px 12px rgba(0,0,0,.08);
}

body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; }

/* ── Navbar ─────────────────────────────────────────────── */
.navbar {
  display: flex; align-items: center; gap: 24px;
  background: #fff; border-bottom: 1px solid var(--border);
  padding: 0 32px; height: 60px; position: sticky; top: 0; z-index: 100;
}
.brand { font-size: 1.3rem; font-weight: 700; color: var(--blue); text-decoration: none; }
.nav-links { display: flex; list-style: none; gap: 4px; align-items: center; flex: 1; }
.nav-links a, .nav-links span { padding: 6px 14px; border-radius: 8px; text-decoration: none;
  color: var(--text); font-size: 14px; font-weight: 500; cursor: pointer; transition: background .15s; }
.nav-links a:hover, .nav-links span:hover { background: var(--blue-bg); color: var(--blue); }
.nav-right { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.welcome { font-size: 14px; color: var(--muted); }

/* Dropdown */
.dropdown { position: relative; }
.dropdown-menu { display: none; position: absolute; top: 100%; left: 0; background: #fff;
  border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow);
  min-width: 180px; padding: 6px; z-index: 200; }
.dropdown:hover .dropdown-menu { display: block; }
.dropdown-menu li { list-style: none; }
.dropdown-menu a { display: block; padding: 8px 14px; border-radius: 8px;
  text-decoration: none; color: var(--text); font-size: 14px; }
.dropdown-menu a:hover { background: var(--blue-bg); color: var(--blue); }

/* ── Main ───────────────────────────────────────────────── */
.main-content { min-height: calc(100vh - 60px); }

/* ── Auth pages ─────────────────────────────────────────── */
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.auth-card { width: 100%; max-width: 440px; padding: 40px; }
.brand-title { font-size: 2rem; font-weight: 700; color: var(--blue); text-align: center; margin-bottom: 4px; }
.brand-sub { text-align: center; color: var(--muted); margin-bottom: 28px; }
.auth-link { text-align: center; margin-top: 16px; font-size: 14px; color: var(--muted); }
.auth-link a { color: var(--blue); text-decoration: none; font-weight: 500; }

/* ── Card ───────────────────────────────────────────────── */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px; }
.form-card { max-width: 700px; margin: 0 auto; }

/* ── Buttons ────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 10px 20px;
  border-radius: 8px; font-size: 14px; font-weight: 600; text-decoration: none;
  border: none; cursor: pointer; transition: all .15s; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--blue-l); }
.btn-outline { background: transparent; color: var(--blue); border: 1.5px solid var(--blue); }
.btn-outline:hover:not(:disabled) { background: var(--blue-bg); }
.btn-block { display: flex; justify-content: center; width: 100%; margin-top: 6px; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

/* ── Forms ──────────────────────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.req { color: var(--red); }
input[type=text], input[type=email], input[type=password], input[type=url],
textarea, select {
  width: 100%; padding: 10px 14px; border: 1.5px solid var(--border); border-radius: 8px;
  font-size: 14px; font-family: inherit; background: #fff; transition: border-color .15s;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(59,91,219,.12); }
textarea { resize: vertical; min-height: 90px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 4px; display: block; }
.content-editor { font-family: 'Consolas','Courier New',monospace; font-size: 13px;
  line-height: 1.7; min-height: 300px; border-radius: 10px; }

/* ── Alerts ─────────────────────────────────────────────── */
.alert { padding: 14px 18px; border-radius: 10px; margin-bottom: 18px; font-size: 14px; }
.alert p + p { margin-top: 4px; }
.alert a { font-weight: 600; }
.alert-success { background: #ebfbee; border: 1px solid #8ce99a; color: #2f9e44; }
.alert-error   { background: #fff5f5; border: 1px solid #ffc9c9; color: var(--red); }

/* ── Page layout ────────────────────────────────────────── */
.page-wrap { max-width: 900px; margin: 0 auto; padding: 40px 24px; }
.page-header { margin-bottom: 32px; }
.page-header h1 { font-size: 1.8rem; font-weight: 700; margin-bottom: 6px; }
.page-sub { color: var(--muted); font-size: 15px; }
.section-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 16px; }

/* ── Dashboard Stats ────────────────────────────────────── */
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 36px; }
@media (max-width: 700px) { .stat-row { grid-template-columns: repeat(2,1fr); } }
.stat-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px; display: flex; align-items: center; gap: 16px;
  border-left: 4px solid var(--accent, var(--blue)); }
.stat-icon { font-size: 2rem; }
.stat-num  { font-size: 1.8rem; font-weight: 700; color: var(--accent, var(--blue)); line-height: 1; }
.stat-label { font-size: 13px; color: var(--muted); margin-top: 2px; }

/* ── Action cards ───────────────────────────────────────── */
.action-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 700px) { .action-row { grid-template-columns: 1fr; } }
.action-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 24px; text-decoration: none; color: var(--text); transition: transform .15s, box-shadow .15s;
  display: flex; flex-direction: column; gap: 10px; }
.action-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,.12); }
.action-icon { font-size: 2rem; }
.action-card h3 { font-size: 1rem; font-weight: 700; }
.action-card p { font-size: 13px; color: var(--muted); flex: 1; }

/* ── Content list ───────────────────────────────────────── */
.content-list { display: flex; flex-direction: column; gap: 10px; }
.content-row { display: flex; align-items: center; gap: 14px; background: var(--card);
  padding: 14px 18px; border-radius: 10px; box-shadow: var(--shadow); text-decoration: none;
  color: var(--text); transition: background .1s; }
.content-row:hover { background: var(--blue-bg); }
.content-preview { flex: 1; font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.content-date { font-size: 12px; color: var(--muted); white-space: nowrap; }

/* Badges */
.badge { font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 20px; white-space: nowrap; text-transform: uppercase; }
.badge-blog   { background: #dbe4ff; color: var(--blue); }
.badge-social { background: #ffe0f0; color: var(--pink); }
.badge-email  { background: #d3f9d8; color: var(--green); }

/* ── Toolbar (saved content) ────────────────────────────── */
.content-toolbar { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.filter-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.filter-tab { padding: 6px 16px; border-radius: 20px; font-size: 13px; font-weight: 600;
  text-decoration: none; color: var(--muted); border: 1.5px solid var(--border); background: #fff; transition: all .15s; }
.filter-tab.active, .filter-tab:hover { background: var(--blue); color: #fff; border-color: var(--blue); }
.search-form { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.search-input { width: 220px; padding: 8px 12px; border: 1.5px solid var(--border);
  border-radius: 8px; font-size: 13px; }

/* ── Empty state ────────────────────────────────────────── */
.empty-state { text-align: center; padding: 60px 24px; color: var(--muted);
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); }
.empty-state p { margin: 12px 0 20px; font-size: 15px; }

/* ── OTP boxes ──────────────────────────────────────────── */
.otp-boxes { display: flex; gap: 10px; justify-content: center; margin: 16px 0; }
.otp-input { width: 52px; height: 58px; text-align: center; font-size: 1.5rem; font-weight: 700;
  border: 2px solid var(--border); border-radius: 10px; padding: 0; }
.otp-input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(59,91,219,.15); }

/* ── Platform toggle ────────────────────────────────────── */
.platform-toggle { display: flex; gap: 12px; flex-wrap: wrap; }
.toggle-opt { display: flex; align-items: center; gap: 8px; padding: 10px 20px;
  border: 2px solid var(--border); border-radius: 10px; cursor: pointer; font-weight: 600;
  font-size: 15px; transition: all .15s; }
.toggle-opt.active { border-color: var(--blue); background: var(--blue-bg); color: var(--blue); }
.toggle-opt input { display: none; }

/* ── Upload area ────────────────────────────────────────── */
.upload-area { border: 2px dashed var(--border); border-radius: 12px; padding: 32px;
  text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.upload-area:hover, .upload-area.dragover { border-color: var(--blue); background: var(--blue-bg); }
.upload-area p { font-size: 14px; color: var(--muted); margin: 6px 0; }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 600px) {
  .navbar { padding: 0 16px; gap: 10px; }
  .nav-links { display: none; }
  .page-wrap { padding: 24px 16px; }
  .auth-card { padding: 28px 20px; }
  .otp-boxes { gap: 6px; }
  .otp-input { width: 40px; height: 48px; font-size: 1.2rem; }
}
