:root {
  --bg: linear-gradient(135deg, #0ea5e9 0%, #8b5cf6 45%, #ef4444 100%);
  --surface: #0b1220;
  --card: rgba(255,255,255,0.08);
  --text: #e6eaf2;
  --muted: #9aa4b2;
  --primary: #a78bfa;
  --ring: rgba(167, 139, 250, 0.35);
  --border: rgba(255,255,255,0.12);
}

[data-theme="light"] {
  --bg: linear-gradient(135deg, #e0f2fe 0%, #ede9fe 45%, #fee2e2 100%);
  --surface: #ffffff;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #4b5563;
  --primary: #6d28d9;
  --ring: rgba(109, 40, 217, 0.22);
  --border: #e5e7eb;
}

[data-theme="dark"] {
  --bg: linear-gradient(135deg, #0b1220 0%, #111827 45%, #0b1220 100%);
  --surface: #0b1220;
  --card: rgba(255,255,255,0.06);
  --text: #e6eaf2;
  --muted: #9aa4b2;
  --primary: #a78bfa;
  --ring: rgba(167, 139, 250, 0.28);
  --border: rgba(255,255,255,0.12);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, "Noto Sans Bengali", system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  background: var(--bg);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.6;
}

.app-header { padding: 12px 16px 8px;  top: 0; z-index: 50; backdrop-filter: blur(10px); }
.brand-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 1040px; margin: 0 auto; padding: 6px 0; }
.brand-left { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 28px; width: auto; object-fit: contain; filter: drop-shadow(0 2px 6px rgba(0,0,0,0.2)); }
.brand-name { font-weight: 800; letter-spacing: 0.3px; }
.subtitle { color: var(--muted); margin: 8px auto 0; max-width: 1040px; font-size: 24px; text-align: center; font-weight: bold; }

.promo-banner { max-width: 1040px; margin: 8px auto 8px; position: relative; border-radius: 16px; background: var(--card); overflow: hidden; }
.promo-banner::before { content: ""; position: absolute; inset: 0; padding: 2px; border-radius: 18px; background: linear-gradient(90deg,#22d3ee,#a78bfa,#ef4444,#22d3ee); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: bannerBorder 6s linear infinite; }
@keyframes bannerBorder { 0%{background-position:0% 50%} 100%{background-position:200% 50%} }
.promo-banner > * { position: relative; z-index: 1; }
.promo-track { display: grid; grid-auto-flow: column; grid-auto-columns: 100%; transition: transform 400ms ease; }
.promo-slide { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; text-decoration: none; color: inherit; }
.promo-slide:hover { background: rgba(255,255,255,0.04); }
.promo-copy { display: grid; }
.promo-copy strong { font-weight: 800; }
.promo-cta { font-weight: 700; }
.promo-dots { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-top: 1px solid var(--border); }
.dot { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--border); background: transparent; cursor: pointer; }
.dot.active { background: var(--primary); border-color: var(--primary); }

.container {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: 16px;
}

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

.sidebar {
  position: relative;
}

.content { display: grid; gap: 16px; }

@media (min-width: 960px) {
  .layout {
    grid-template-columns: 360px 1fr;
    align-items: start;
  }
  .sidebar { position: sticky; top: 16px; height: fit-content; }
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 24px 48px rgba(0,0,0,0.25);
}

.content .card {
  box-shadow: none;
  backdrop-filter: none;
}

.section-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #22d3ee, #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section-title { margin: 0 0 12px; font-size: 18px; }

.form { display: grid; gap: 12px; }
.software-fields { border-top: 1px dashed var(--border); padding-top: 12px; }
.software-fields .form-row label { font-weight: 600; }
.step-title { font-weight: 800; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.6px; }
.advanced summary { cursor: pointer; font-weight: 700; }
.advanced[open] { border-top: 1px dashed var(--border); padding-top: 10px; }
.form-row { display: grid; gap: 8px; }
.label-row { display: flex; align-items: center; justify-content: space-between; }

label { font-weight: 600; }
.hint { color: var(--muted); font-size: 12px; }

input[type="text"], select, textarea, .output {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  color: var(--text);
  outline: none;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

input:focus, select:focus, textarea:focus, .output:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--ring);
}

.actions { display: flex; gap: 8px; }

.btn {
  appearance: none;
  border: 0;
  background: linear-gradient(135deg, #4f46e5, #a78bfa);
  color: #fff;
  padding: 10px 14px;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: 0.2px;
  cursor: pointer;
  transition: transform 0.02s ease, box-shadow 0.15s ease, background 0.15s ease, filter 0.2s ease;
  text-decoration: none;
}
.btn:hover { filter: brightness(1.05); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}
.btn-ghost:hover { background: rgba(255,255,255,0.05); }
.small { padding: 6px 10px; font-size: 12px; }

.output-header, .history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.history-list { display: grid; gap: 10px; }
.history-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  background: #fff;
}
.history-meta { color: var(--muted); font-size: 12px; margin-bottom: 8px; }
.history-actions { display: flex; gap: 8px; }

.app-footer { text-align: center; color: var(--muted); padding: 24px 16px; }

@media (min-width: 880px) {
  .container {
    grid-template-columns: 1fr;
  }
}


