:root {
  --bg: #0c0c0c;
  --bg-2: #121210;
  --ink: #f2efe7;
  --ink-soft: #a3a296;
  --line: #2b2a26;
  --yellow: #ffb300;
  --yellow-ink: #171300;
  --yellow-hover: #ffc44d;
  --danger: #e5484d;
  --font-bangla: "Anek Bangla", "Hind Siliguri", sans-serif;
  --font-display: "Anton", "Anek Bangla", sans-serif;
  --font-body: "Hind Siliguri", "Anek Bangla", sans-serif;
  --shadow-yellow: 6px 6px 0 rgba(255, 179, 0, 0.28);
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; font-family: var(--font-bangla); color: var(--ink); font-weight: 700; line-height: 1.35; }
p { margin: 0; }
a { color: inherit; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }

:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }

.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  background: var(--yellow);
  border: 2px solid var(--yellow);
}
.brand-mark img.brand-logo { width: 30px; height: 30px; display: block; }
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-family: var(--font-bangla); font-size: 1rem; font-weight: 700; line-height: 1.3; color: var(--ink); }
.brand-sub { font-size: 0.6875rem; color: var(--ink-soft); line-height: 1.3; }

/* ---------- login ---------- */

.login-body {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
  overflow: hidden;
  background: var(--bg);
}
.login-body::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(720px 480px at 82% 0%, rgba(255, 179, 0, 0.14), transparent 62%), linear-gradient(rgba(242, 239, 231, 0.045) 1px, transparent 1px), linear-gradient(90deg, rgba(242, 239, 231, 0.045) 1px, transparent 1px);
  background-size: auto, 56px 56px, 56px 56px;
  pointer-events: none;
}
.login-shell { position: relative; width: 100%; max-width: 430px; }
.login-brand { margin-bottom: 20px; }
.login-brand .brand-name { color: var(--ink); }
.login-brand .brand-sub { color: var(--ink-soft); }
.login-card { padding: clamp(24px, 4vw, 36px); background: var(--bg-2); border: 2px solid var(--line); border-radius: 0; box-shadow: 10px 10px 0 rgba(255, 179, 0, 0.1); }
.login-kicker { margin: 0 0 8px; font-family: var(--font-display); font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--yellow); }
.login-card h1 { font-size: 1.6rem; }
.login-sub { margin: 8px 0 22px; font-size: 0.9375rem; color: var(--ink-soft); }
.field { display: block; margin-bottom: 16px; }
.field > span { display: block; margin-bottom: 6px; font-size: 0.8125rem; font-weight: 600; color: #d8d2c4; }
input[type="text"], input[type="email"], input[type="password"], input[type="url"], input[type="tel"], input:not([type]), textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg);
  color: var(--ink);
  border: 2px solid var(--line);
  border-radius: 0;
  font-size: 0.9688rem;
  line-height: 1.5;
}
textarea { resize: vertical; min-height: 90px; }
input:focus, textarea:focus { outline: none; border-color: var(--yellow); }
.form-error { margin: 0 0 14px; padding: 10px 12px; background: rgba(229, 72, 77, 0.12); border: 2px solid var(--danger); color: #f1948a; font-size: 0.875rem; line-height: 1.5; }
.login-btn { width: 100%; min-height: 52px; background: var(--yellow); color: var(--yellow-ink); border: 2px solid var(--yellow); border-radius: 0; font-weight: 700; font-size: 1rem; }
.login-btn:hover { background: var(--yellow-hover); }
.back-link { display: inline-block; margin-top: 18px; font-size: 0.875rem; color: var(--ink-soft); text-decoration: none; }
.back-link:hover { color: var(--yellow); }

/* ---------- admin layout ---------- */

.admin-body { min-height: 100vh; background: var(--bg); }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 20; display: flex; flex-direction: column; width: 268px; padding: 22px 16px; background: var(--bg); border-right: 2px solid var(--line); }
.side-brand { padding: 4px 6px 20px; }
.side-brand .brand-name { color: var(--ink); }
.side-brand .brand-sub { color: var(--ink-soft); }
.side-nav { display: flex; flex-direction: column; gap: 3px; }
.side-link { width: 100%; padding: 10px 12px; background: transparent; color: var(--ink-soft); border: 0; border-radius: 0; font-size: 0.9375rem; font-weight: 500; text-align: left; }
.side-link:hover { background: rgba(242, 239, 231, 0.06); color: var(--ink); }
.side-link.is-active { background: var(--yellow); color: var(--yellow-ink); font-weight: 700; }
.side-foot { display: flex; flex-direction: column; gap: 2px; margin-top: auto; padding-top: 18px; border-top: 2px solid var(--line); }
.side-action { padding: 9px 12px; background: transparent; color: var(--ink-soft); border: 0; border-radius: 0; font-size: 0.875rem; text-align: left; text-decoration: none; }
.side-action:hover { background: rgba(242, 239, 231, 0.06); color: var(--ink); }
.admin-main { min-height: 100vh; margin-left: 268px; padding: 0 clamp(18px, 3vw, 36px) 56px; background: var(--bg); }
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 0 16px; background: rgba(12, 12, 12, 0.95); border-bottom: 2px solid var(--line); backdrop-filter: blur(10px); }
.top-kicker { margin: 0 0 2px; font-family: var(--font-display); font-size: 0.6875rem; font-weight: 400; letter-spacing: 0.08em; text-transform: uppercase; color: var(--yellow); }
.topbar h1 { font-size: 1.35rem; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.preview-link { padding: 10px 14px; border: 2px solid var(--line); background: var(--bg-2); color: var(--ink); border-radius: 0; font-size: 0.875rem; font-weight: 600; text-decoration: none; }
.preview-link:hover { border-color: var(--yellow); }
.save-btn { min-height: 44px; padding: 0 20px; background: var(--yellow); color: var(--yellow-ink); border: 2px solid var(--yellow); border-radius: 0; font-weight: 700; font-size: 0.9375rem; }
.save-btn:hover { background: var(--yellow-hover); }
.save-btn:disabled { opacity: 0.6; cursor: wait; }
.save-btn.is-dirty { box-shadow: 0 0 0 3px rgba(255, 179, 0, 0.25); }
.panel { display: none; }
.panel.is-active { display: block; }
.card { padding: clamp(20px, 2.6vw, 28px); margin-bottom: 18px; background: var(--bg-2); border: 2px solid var(--line); border-radius: 0; }
.card-narrow { max-width: 560px; }
.card h2 { font-size: 1.15rem; }
.hint { margin: 5px 0 20px; font-size: 0.875rem; color: var(--ink-soft); }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.image-field { display: grid; grid-template-columns: minmax(0, 280px) minmax(0, 1fr); gap: 20px; align-items: center; }
.image-field img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border: 2px solid var(--line); border-radius: 0; background: var(--bg); }
.image-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.upload-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 18px; background: var(--bg-2); color: var(--ink); border: 2px solid var(--line); border-radius: 0; font-size: 0.9375rem; font-weight: 600; }
.upload-btn:hover { border-color: var(--yellow); }
.upload-status { font-size: 0.8125rem; color: var(--ink-soft); line-height: 1.5; }
.upload-status.is-error { color: #f1948a; }
.upload-status.is-ok { color: #7fd6a4; }
.service-edit { padding: 16px 0; border-top: 2px solid var(--line); }
.service-edit:first-of-type { border-top: 0; padding-top: 0; }
.service-edit h3 { margin-bottom: 12px; font-size: 0.9375rem; color: #d8d2c4; }

/* ---------- toast ---------- */

.toast { position: fixed; top: 18px; right: 22px; z-index: 90; max-width: min(360px, calc(100vw - 32px)); padding: 13px 18px; background: var(--bg-2); color: var(--ink); border: 2px solid var(--line); border-radius: 0; font-size: 0.9375rem; box-shadow: 6px 6px 0 rgba(255, 179, 0, 0.18); opacity: 0; transform: translateY(-10px); pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease; }
.toast.show { opacity: 1; transform: none; }
.toast.is-error { border-color: var(--danger); background: rgba(229, 72, 77, 0.14); }

@media (max-width: 900px) {
  .sidebar { position: static; width: auto; padding: 14px 16px; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; background: var(--bg); border-right: 0; border-bottom: 2px solid var(--line); }
  .side-brand { padding: 0; margin-right: auto; }
  .side-nav { order: 3; width: 100%; flex-direction: row; overflow-x: auto; gap: 4px; padding-top: 8px; }
  .side-link { width: auto; white-space: nowrap; font-size: 0.875rem; }
  .side-foot { flex-direction: row; margin: 0; padding: 0; border: 0; }
  .admin-main { margin-left: 0; }
}

@media (max-width: 640px) {
  .topbar { flex-wrap: wrap; padding-top: 16px; }
  .top-actions { width: 100%; }
  .save-btn { flex: 1; }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .image-field { grid-template-columns: minmax(0, 1fr); }
  .image-field img { max-width: 100%; }
  .side-foot .side-action { font-size: 0.8125rem; padding: 6px 8px; }
}
