/* AI Mortgage Forecast — self-hosted utility layer (replaces Tailwind CDN) */

/* ---------- Preflight (minimal reset, mirrors Tailwind's base layer) ---------- */
*, *::before, *::after { box-sizing: border-box; border-width: 0; border-style: solid; border-color: #e2e8f0; }
html { line-height: 1.5; -webkit-text-size-adjust: 100%; tab-size: 4; font-family: Inter, ui-sans-serif, system-ui, -apple-system, sans-serif; }
body { margin: 0; line-height: inherit; }
h1, h2, h3, h4, h5, h6 { font-size: inherit; font-weight: inherit; margin: 0; }
p { margin: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }
a { color: inherit; text-decoration: inherit; }
button, input, optgroup, select, textarea { font-family: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; }
button, select { text-transform: none; }
button { cursor: pointer; background-color: transparent; background-image: none; }
img, svg { display: block; vertical-align: middle; }
table { border-collapse: collapse; text-indent: 0; border-color: inherit; }
:root { -webkit-tap-highlight-color: transparent; }

/* ---------- Layout ---------- */
.block { display: block; }
.inline-block { display: inline-block; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.grid { display: grid; }
.hidden { display: none; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-shrink-0 { flex-shrink: 0; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-baseline { align-items: baseline; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.group { }

.fixed { position: fixed; }
.sticky { position: sticky; }
.inset-0 { inset: 0; }
.top-0 { top: 0; }
.right-0 { right: 0; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.list-none { list-style: none; }
.not-prose { }
.overflow-x-auto { overflow-x: auto; }
.cursor-pointer { cursor: pointer; }
.pointer-events-none { pointer-events: none; }

/* ---------- Spacing: gap ---------- */
.gap-1 { gap: 0.25rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-5 { gap: 1.25rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }

/* ---------- Spacing: margin ---------- */
.mx-auto { margin-left: auto; margin-right: auto; }
.mx-3 { margin-left: 0.75rem; margin-right: 0.75rem; }
.my-2 { margin-top: 0.5rem; margin-bottom: 0.5rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-5 { margin-bottom: 1.25rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-14 { margin-bottom: 3.5rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-1\.5 { margin-top: 0.375rem; }
.mt-2 { margin-top: 0.5rem; }
.-mt-2 { margin-top: -0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }

/* ---------- Spacing: padding ---------- */
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-5 { padding-left: 1.25rem; padding-right: 1.25rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-14 { padding-top: 3.5rem; padding-bottom: 3.5rem; }
.pt-4 { padding-top: 1rem; }
.pt-6 { padding-top: 1.5rem; }

/* ---------- Spacing: space-between children ---------- */
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }

/* ---------- Sizing ---------- */
.w-3 { width: 0.75rem; }
.w-3\.5 { width: 0.875rem; }
.w-4 { width: 1rem; }
.w-5 { width: 1.25rem; }
.w-8 { width: 2rem; }
.w-9 { width: 2.25rem; }
.w-11 { width: 2.75rem; }
.w-16 { width: 4rem; }
.w-72 { width: 18rem; }
.w-full { width: 100%; }
.h-0\.5 { height: 0.125rem; }
.h-3\.5 { height: 0.875rem; }
.h-4 { height: 1rem; }
.h-5 { height: 1.25rem; }
.h-8 { height: 2rem; }
.h-9 { height: 2.25rem; }
.h-11 { height: 2.75rem; }
.h-16 { height: 4rem; }
.h-48 { height: 12rem; }
.h-full { height: 100%; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-6xl { max-width: 72rem; }
.max-w-7xl { max-width: 80rem; }

/* ---------- Typography ---------- */
.antialiased { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-extrabold { font-weight: 800; }
.leading-tight { line-height: 1.25; }
.leading-relaxed { line-height: 1.625; }
.tracking-tight { letter-spacing: -0.025em; }
.tracking-wide { letter-spacing: 0.025em; }
.uppercase { text-transform: uppercase; }
.underline { text-decoration-line: underline; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border-width: 0; }

/* ---------- Borders / radius / shadow ---------- */
.border { border-width: 1px; }
.border-t { border-top-width: 1px; }
.border-b { border-bottom-width: 1px; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }
.shadow-sm { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
.shadow-md { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.shadow-2xl { box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25); }

/* ---------- Colors: brand palette (Wisteria) ---------- */
.bg-brand-50 { background-color: #f8f5f7; }
.bg-brand-100 { background-color: #ece0e9; }
.bg-brand-700 { background-color: #6d4a67; }
.bg-brand-950 { background-color: #281a26; }
.hover\:bg-brand-50:hover { background-color: #f8f5f7; }
.hover\:bg-brand-800:hover { background-color: #573b4e; }
.border-brand-200 { border-color: #e1ccdb; }
.border-brand-800 { border-color: #573b4e; }
.text-brand-100 { color: #ece0e9; }
.text-brand-700 { color: #6d4a67; }
.hover\:text-brand-700:hover { color: #6d4a67; }
.focus\:ring-brand-500:focus { --tw-ring-color: #a67d9e; }
.focus\:border-brand-500:focus { border-color: #a67d9e; }
.from-brand-50 { --gradient-from: #f8f5f7; }

/* ---------- Colors: slate ---------- */
.bg-slate-50 { background-color: #f8fafc; }
.bg-slate-400 { background-color: #94a3b8; }
.bg-slate-900\/40 { background-color: rgb(15 23 42 / 0.4); }
.border-slate-100 { border-color: #f1f5f9; }
.border-slate-200 { border-color: #e2e8f0; }
.border-slate-300 { border-color: #cbd5e1; }
.text-slate-300 { color: #cbd5e1; }
.text-slate-400 { color: #94a3b8; }
.text-slate-500 { color: #64748b; }
.text-slate-600 { color: #475569; }
.text-slate-700 { color: #334155; }
.text-slate-800 { color: #1e293b; }
.text-slate-900 { color: #0f172a; }
.hover\:bg-slate-50:hover { background-color: #f8fafc; }
.to-slate-50 { --gradient-to: #f8fafc; }

/* ---------- Colors: amber ---------- */
.text-amber-800 { color: #92400e; }
.text-amber-900 { color: #78350f; }

/* ---------- Colors: white / misc ---------- */
.bg-white { background-color: #fff; }
.bg-white\/80 { background-color: rgb(255 255 255 / 0.8); }
.hover\:bg-white:hover { background-color: #fff; }
.text-white { color: #fff; }
.hover\:text-white:hover { color: #fff; }
.bg-gradient-to-b { background-image: linear-gradient(to bottom, var(--gradient-from), var(--gradient-to)); }

/* ---------- Effects / transitions ---------- */
.opacity-0 { opacity: 0; }
.duration-300 { transition-duration: 300ms; }
.transition-colors { transition-property: color, background-color, border-color; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-opacity { transition-property: opacity; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-shadow { transition-property: box-shadow; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-transform { transition-property: transform; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.translate-x-full { transform: translateX(100%); }
.hover\:shadow-md:hover { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.focus\:ring-2:focus { box-shadow: 0 0 0 2px var(--tw-ring-color, #a67d9e); outline: none; }
.group[open] .group-open\:rotate-180 { transform: rotate(180deg); }

/* ---------- Responsive: sm (>=640px) ---------- */
@media (min-width: 640px) {
  .sm\:block { display: block; }
  .sm\:flex { display: flex; }
  .sm\:flex-row { flex-direction: row; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sm\:px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
  .sm\:py-14 { padding-top: 3.5rem; padding-bottom: 3.5rem; }
  .sm\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
}

/* ---------- Responsive: lg (>=1024px) ---------- */
@media (min-width: 1024px) {
  .lg\:col-span-1 { grid-column: span 1 / span 1; }
  .lg\:col-span-2 { grid-column: span 2 / span 2; }
  .lg\:flex { display: flex; }
  .lg\:hidden { display: none; }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lg\:px-8 { padding-left: 2rem; padding-right: 2rem; }
  .lg\:text-5xl { font-size: 3rem; line-height: 1; }
}
