@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&family=Inter:wght@300;400;500;600&display=swap');

:root {
  --bg: #FFFFFF;
  --surface: #F6F8F6;
  --surface-2: #EDF0ED;
  --border: #D8DED8;
  --border-light: #E8ECE8;
  --text: #111811;
  --text-muted: #52645A;
  --text-light: #8A9E93;
  --primary: #1C3829;
  --primary-hover: #142A1E;
  --primary-light: #EAF0EC;
  --gold: #B8952A;
  --gold-hover: #9A7C22;
  --gold-light: #FBF5E6;
  --gold-border: #D4AF50;
  --accent: #1C3829;
  --accent-light: #EAF0EC;
  --success: #1A7F4B;
  --success-light: #E6F4ED;
  --white: #FFFFFF;
  --red: #C0392B;
  --red-light: #FDEEEC;
  --radius: 8px;
  --radius-sm: 5px;
  --radius-lg: 14px;
  --shadow: 0 1px 3px rgba(28,56,41,0.07), 0 4px 12px rgba(28,56,41,0.05);
  --shadow-md: 0 2px 8px rgba(28,56,41,0.08), 0 8px 24px rgba(28,56,41,0.06);
  --shadow-lg: 0 4px 16px rgba(28,56,41,0.1), 0 16px 48px rgba(28,56,41,0.08);
  --nav-h: 64px;
  --max-w: 1200px;
  --transition: 180ms ease;
}

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

html { font-size: 16px; scroll-behavior: smooth; }

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

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ── Typography ─────────────────────────────────── */
.font-display { font-family: 'Playfair Display', Georgia, serif; }
h1, h2, h3 { line-height: 1.25; }

/* ── Layout ─────────────────────────────────────── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
.section { padding: 64px 0; }
.section-sm { padding: 40px 0; }

/* ── Navigation ─────────────────────────────────── */
body > nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(28,56,41,0.97);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  z-index: 100;
  display: flex;
  align-items: center;
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.02em;
  white-space: nowrap;
}
body > nav .nav-logo { color: var(--white); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}

.nav-links a:hover { color: var(--white); background: rgba(255,255,255,0.08); }
.nav-links a.active { color: var(--gold); }

.nav-browse-btn {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  background: var(--gold);
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--gold);
  transition: background var(--transition), border-color var(--transition);
}
.nav-browse-btn:hover { background: var(--gold-hover); border-color: var(--gold-hover); }

/* ── Hero ───────────────────────────────────────── */
.hero {
  margin-top: var(--nav-h);
  background: #FFFFFF;
  padding: 88px 24px 100px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--gold);
  background: var(--gold-light);
  border: 1px solid var(--gold-border);
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 24px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.hero p {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  font-weight: 400;
}

/* ── Search ─────────────────────────────────────── */
.search-wrap {
  position: relative;
  max-width: 620px;
  margin: 0 auto;
}

.search-bar {
  display: flex;
  align-items: center;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 999px;
  padding: 8px 8px 8px 20px;
  gap: 8px;
  box-shadow: var(--shadow-md);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.search-bar:focus-within {
  border-color: var(--gold-border);
  box-shadow: 0 0 0 3px rgba(184,149,42,0.18), var(--shadow-md);
}

.search-icon {
  color: var(--text-light);
  flex-shrink: 0;
  width: 18px;
  height: 18px;
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 1rem;
  color: var(--text);
  background: transparent;
  min-width: 0;
}

.search-input::placeholder { color: var(--text-light); }

.search-btn {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--white);
  background: var(--primary);
  padding: 10px 22px;
  border-radius: 999px;
  transition: background var(--transition);
  white-space: nowrap;
}
.search-btn:hover { background: var(--primary-hover); }

.search-browse-link {
  display: block;
  margin-top: 14px;
  font-size: 0.875rem;
  color: var(--text-muted);
}
.search-browse-link a {
  color: var(--primary);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Search dropdown */
.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0; right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 200;
  overflow: hidden;
  display: none;
}
.search-dropdown.open { display: block; }

.search-result-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  cursor: pointer;
  transition: background var(--transition);
  border-bottom: 1px solid var(--border-light);
  text-align: left;
}
.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--surface); }

.search-result-title { font-size: 0.95rem; font-weight: 500; color: var(--text); }
.search-result-meta { font-size: 0.8rem; color: var(--text-muted); margin-top: 2px; }
.search-result-price {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold);
  white-space: nowrap;
  margin-left: 12px;
}

.search-no-results {
  padding: 16px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ── Buttons ─────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  white-space: nowrap;
  border: 1.5px solid transparent;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { background: var(--surface-2); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover { background: var(--primary-light); }

.btn-success {
  background: var(--success);
  color: var(--white);
  border-color: var(--success);
}

.btn-lg { font-size: 1rem; padding: 14px 28px; border-radius: var(--radius); }
.btn-full { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Form Cards ──────────────────────────────────── */
.forms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.form-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.form-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.form-card-preview {
  height: 180px;
  background: var(--surface);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-light);
}

.form-card-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.form-card-preview .no-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-light);
  font-size: 0.8rem;
}

.form-card-body { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.form-card-category {
  font-size: 0.73rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin-bottom: 6px;
}
.form-card-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
  flex: 1;
}
.form-card-price {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--gold);
  margin-top: 10px;
}
.form-card-price.free { color: var(--success); }
.form-card-price.temp-free { color: var(--gold-hover); background: var(--gold-light); border-radius: 4px; padding: 1px 7px; font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; }
.form-card-price-orig { font-size: 0.8rem; font-weight: 500; color: var(--text-light); text-decoration: line-through; margin-left: 6px; }

/* ── Form Detail Page ────────────────────────────── */
.form-detail-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 40px;
  align-items: start;
}

.form-preview-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  position: sticky;
  top: calc(var(--nav-h) + 24px);
}

.form-preview-img {
  width: 100%;
  display: block;
}

.form-preview-placeholder {
  height: 500px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--text-muted);
}

.form-info-panel {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-info-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 24px;
}

.form-title-main {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 8px;
}

.form-category-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  background: var(--accent-light);
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.form-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  padding: 8px 0;
  border-bottom: 1px solid var(--border-light);
}
.form-meta-row:last-of-type { border-bottom: none; }
.form-meta-label { font-weight: 500; color: var(--text); min-width: 110px; }

.price-display {
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
}
.price-display.free { color: var(--success); }

.form-tags-wrap { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.tag-chip {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 3px 10px;
  border-radius: 999px;
}

/* ── About section ───────────────────────────────── */
.about-section {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 32px;
  margin-top: 40px;
}
.about-section h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  margin-bottom: 16px;
  color: var(--text);
}
.about-section p {
  color: var(--text-muted);
  line-height: 1.75;
  font-size: 0.95rem;
}

/* ── Related Forms ───────────────────────────────── */
.related-section { margin-top: 48px; }
.section-heading {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  color: var(--text);
  margin-bottom: 24px;
}

/* ── Checkout ────────────────────────────────────── */
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 40px;
  align-items: start;
}

.checkout-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 24px;
}
.checkout-card h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  margin-bottom: 20px;
  color: var(--text);
}

.cart-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}
.cart-item:last-child { border-bottom: none; }
.cart-item-preview {
  width: 56px;
  height: 72px;
  object-fit: cover;
  object-position: top;
  border-radius: var(--radius-sm);
  background: var(--surface);
  flex-shrink: 0;
  border: 1px solid var(--border);
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-title { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.cart-item-cat { font-size: 0.78rem; color: var(--text-muted); margin-top: 2px; }
.cart-item-price {
  font-weight: 700;
  color: var(--gold);
  font-size: 0.95rem;
  white-space: nowrap;
}
.cart-item-price .original {
  font-size: 0.78rem;
  color: var(--text-light);
  text-decoration: line-through;
  display: block;
  text-align: right;
}
.cart-remove {
  color: var(--text-light);
  font-size: 0.8rem;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color var(--transition), background var(--transition);
}
.cart-remove:hover { color: var(--red); background: var(--red-light); }

.discount-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--success);
  background: var(--success-light);
  padding: 4px 10px;
  border-radius: 999px;
  margin: 12px 0;
}

.order-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 2px solid var(--border);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}
.order-total-amount { color: var(--gold); }

.upsell-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}
.upsell-item:last-child { border-bottom: none; }
.upsell-img {
  width: 44px;
  height: 56px;
  object-fit: cover;
  object-position: top;
  border-radius: 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  flex-shrink: 0;
}
.upsell-info { flex: 1; min-width: 0; }
.upsell-title { font-size: 0.85rem; font-weight: 500; color: var(--text); }
.upsell-prices { font-size: 0.8rem; margin-top: 2px; }
.upsell-prices .disc { color: var(--gold); font-weight: 700; }
.upsell-prices .orig { color: var(--text-light); text-decoration: line-through; margin-left: 4px; }
.upsell-add {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  border: 1px solid var(--border);
  background: var(--white);
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: all var(--transition);
}
.upsell-add:hover { background: var(--primary-light); border-color: var(--primary); }
.upsell-add.added { background: var(--success-light); color: var(--success); border-color: var(--success); }

/* ── Success page ────────────────────────────────── */
.success-wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 80px 24px;
  text-align: center;
}
.success-icon {
  width: 72px;
  height: 72px;
  background: var(--success-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: var(--success);
}
.success-wrap h1 {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  margin-bottom: 12px;
}
.success-wrap p { color: var(--text-muted); margin-bottom: 32px; }

.download-list { text-align: left; margin-top: 32px; }
.download-item {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 12px;
}
.download-item-title { font-weight: 600; margin-bottom: 10px; font-size: 0.95rem; }
.download-btns { display: flex; gap: 10px; flex-wrap: wrap; }

/* ── Disclaimer ──────────────────────────────────── */
.disclaimer-banner {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 20px 0;
}
.disclaimer-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 880px;
  text-align: justify;
}
.disclaimer-text strong { color: var(--text); }

/* ── Browse page ─────────────────────────────────── */
.browse-header {
  margin-top: var(--nav-h);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 40px 24px;
}
.browse-header h1 {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  margin-bottom: 8px;
}
.browse-header p { color: var(--text-muted); font-size: 0.95rem; }

.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.filter-select {
  appearance: none;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23555B6A' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 9px 36px 9px 14px;
  font-size: 0.875rem;
  color: var(--text);
  cursor: pointer;
  transition: border-color var(--transition);
}
.filter-select:focus { outline: none; border-color: var(--primary); }

.filter-search {
  flex: 1;
  min-width: 200px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 9px 14px;
  font-size: 0.875rem;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--transition);
}
.filter-search:focus { outline: none; border-color: var(--primary); }

.alpha-index {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 32px;
}
.alpha-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  cursor: pointer;
}
.alpha-btn:hover, .alpha-btn.active {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* ── Footer ──────────────────────────────────────── */
footer {
  background: var(--primary);
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 40px 0 24px;
}
.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: start;
}
.footer-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 8px;
}
.footer-tagline { font-size: 0.85rem; color: rgba(255,255,255,0.55); max-width: 340px; }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-links a { font-size: 0.85rem; color: rgba(255,255,255,0.55); transition: color var(--transition); }
.footer-links a:hover { color: var(--gold); }
.footer-copy {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.35);
  text-align: center;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

/* ── Admin ───────────────────────────────────────── */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--text);
  color: var(--white);
  padding: 24px 0;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  overflow-y: auto;
}

.admin-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--white);
  padding: 0 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 16px;
}
.admin-logo span { color: var(--gold); }

.admin-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255,255,255,0.65);
  transition: color var(--transition), background var(--transition);
}
.admin-nav a:hover { color: var(--white); background: rgba(255,255,255,0.06); }
.admin-nav a.active { color: var(--white); background: rgba(255,255,255,0.1); border-right: 3px solid var(--gold); }

.admin-main {
  margin-left: 220px;
  flex: 1;
  padding: 32px;
  min-height: 100vh;
  background: var(--bg);
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}
.admin-topbar h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
}

.stat-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 20px;
}
.stat-card-label { font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); margin-bottom: 8px; }
.stat-card-value { font-size: 1.75rem; font-weight: 700; color: var(--text); }
.stat-card-value.green { color: var(--success); }

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border-light);
  font-size: 0.875rem;
}
.data-table th {
  text-align: left;
  padding: 12px 16px;
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text);
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--bg); }

.badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
}
.badge-green { background: var(--success-light); color: var(--success); }
.badge-gray { background: var(--surface); color: var(--text-muted); }
.badge-gold { background: var(--gold-light); color: var(--gold-hover); }

.action-btns { display: flex; gap: 6px; }
.action-btn {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  color: var(--text-muted);
  background: var(--white);
  transition: all var(--transition);
}
.action-btn:hover { color: var(--text); background: var(--surface); }
.action-btn.danger:hover { color: var(--red); background: var(--red-light); border-color: var(--red); }

/* Admin form */
.admin-form-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}

.form-group { margin-bottom: 18px; }
.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.form-group .hint { font-size: 0.78rem; color: var(--text-muted); margin-top: 4px; }

.form-control {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.9rem;
  color: var(--text);
  background: var(--white);
  transition: border-color var(--transition);
}
.form-control:focus { outline: none; border-color: var(--accent); }

textarea.form-control { resize: vertical; min-height: 100px; }

.file-upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
  background: var(--surface);
}
.file-upload-zone:hover, .file-upload-zone.drag { border-color: var(--accent); background: var(--accent-light); }
.file-upload-zone p { font-size: 0.85rem; color: var(--text-muted); margin-top: 6px; }

.tag-picker { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-option {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition);
  user-select: none;
  background: var(--white);
}
.tag-option input { display: none; }
.tag-option:has(input:checked) {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* ── Alert / Toast ───────────────────────────────── */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--text);
  color: var(--white);
  padding: 12px 20px;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  transform: translateY(20px);
  opacity: 0;
  transition: all 250ms ease;
  pointer-events: none;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { background: var(--success); }
.toast.error { background: var(--red); }

/* ── Utilities ───────────────────────────────────── */
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-24 { margin-bottom: 24px; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.hidden { display: none !important; }

.loading-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.empty-state {
  text-align: center;
  padding: 64px 24px;
  color: var(--text-muted);
}
.empty-state h3 { font-size: 1.1rem; margin-bottom: 8px; color: var(--text); }
.empty-state p { font-size: 0.9rem; }

/* ── Responsive ──────────────────────────────────── */
@media (max-width: 900px) {
  .form-detail-grid { grid-template-columns: 1fr; }
  .form-preview-panel { position: static; }
  .checkout-layout { grid-template-columns: 1fr; }
  .admin-form-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .hero { padding: 56px 20px 72px; }
  .hero h1 { font-size: 1.9rem; }
  .nav-links { display: none; }
  .section { padding: 40px 0; }
  .forms-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
  .admin-sidebar { width: 100%; position: static; }
  .admin-main { margin-left: 0; padding: 20px; }
  .admin-layout { flex-direction: column; }
}

#dev-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
#dev-modal {
  background: #fff;
  border-radius: 16px;
  padding: 52px 44px 44px;
  max-width: 500px;
  width: 90%;
  text-align: center;
  box-shadow: 0 24px 64px rgba(0,0,0,0.35);
}
#dev-icon {
  font-size: 64px;
  line-height: 1;
  color: #f59e0b;
  margin-bottom: 20px;
}
#dev-modal h2 {
  font-size: 1.6rem;
  color: #1a1a1a;
  margin-bottom: 14px;
}
#dev-modal p {
  color: #555;
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 32px;
}
#dev-modal button {
  background: #1a3c34;
  color: #fff;
  border: none;
  padding: 14px 40px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
#dev-modal button:hover { background: #145c46; }
