@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,700;9..144,900&family=Sora:wght@400;500;600;700&display=swap");

:root {
  --bg: #f5efe3;
  --paper: #fffaf2;
  --ink: #1d1f22;
  --muted: #666d73;
  --brand: #005e52;
  --brand-2: #d4542d;
  --line: #d9d2c2;
  --ok: #1f7a45;
  --warn: #a35a00;
  --err: #b42318;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 16px 42px rgba(30, 30, 30, 0.08);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--ink);
  font-family: "Sora", "Avenir Next", "Segoe UI", sans-serif;
  background:
    radial-gradient(1200px 500px at 5% -5%, #f7caa6 0%, transparent 55%),
    radial-gradient(900px 500px at 95% 0%, #b9ebdf 0%, transparent 48%),
    var(--bg);
}

h1, h2, h3, h4 {
  font-family: "Fraunces", Georgia, serif;
  margin: 0;
  letter-spacing: 0.01em;
}

a { color: inherit; text-decoration: none; }

.shell {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  backdrop-filter: blur(6px);
  background: color-mix(in srgb, #fffaf2 88%, transparent);
  border-bottom: 1px solid #ebe3d4;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.brand {
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--brand);
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.nav-link {
  padding: 0.5rem 0.8rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.9rem;
}

.nav-link:hover {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.8);
}

.nav-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  font-size: 0.82rem;
  color: var(--muted);
}

.nav-button {
  font: inherit;
  cursor: pointer;
}

main.shell {
  padding: 1.25rem 0 3rem;
}

.page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.page-head p {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.grid {
  display: grid;
  gap: 1rem;
}

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

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
}

.metric {
  font-size: 2rem;
  line-height: 1;
  color: var(--brand);
  margin-top: 0.5rem;
}

.muted { color: var(--muted); }

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  margin-bottom: 1rem;
}

input[type="text"],
input[type="email"],
input[type="datetime-local"],
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.66rem 0.75rem;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

textarea { min-height: 120px; resize: vertical; }

label {
  font-size: 0.9rem;
  font-weight: 600;
  display: block;
  margin-bottom: 0.35rem;
}

.form-grid {
  display: grid;
  gap: 0.8rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid .full { grid-column: 1 / -1; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 0.55rem 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(115deg, var(--brand), #027462);
  border-color: #01594d;
  color: #fff;
}

.btn-danger {
  border-color: #f2d0cc;
  background: #fff5f4;
  color: var(--err);
}

.btn:hover { filter: brightness(0.98); }

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #fff;
}

.table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

.table th,
.table td {
  text-align: left;
  padding: 0.7rem;
  border-bottom: 1px solid #ece4d5;
  font-size: 0.93rem;
  vertical-align: top;
}

.table th {
  color: #50555b;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.badge-pending { background: #ffefcc; color: #8b5200; }
.badge-processing { background: #dbecff; color: #004b8f; }
.badge-complete { background: #d6f6e4; color: #0d6a36; }
.badge-failed { background: #ffe0dc; color: #9f1d1d; }

.file-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.7rem;
  border-radius: 999px;
  padding: 0.2rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  background: #f3f4f6;
  color: #364152;
}

.file-icon-pdf { background: #fee4e2; color: #912018; border-color: #fecdca; }
.file-icon-img { background: #dff8eb; color: #075b38; border-color: #b7ebd0; }
.file-icon-txt { background: #e8efff; color: #1d3f91; border-color: #cdddfa; }
.file-icon-doc { background: #e6f4ff; color: #175cd3; border-color: #cbe8ff; }
.file-icon-xls { background: #dcfae6; color: #067647; border-color: #abefc6; }
.file-icon-ppt { background: #ffead5; color: #9c2a10; border-color: #ffd6ae; }
.file-icon-generic { background: #f2f4f7; color: #344054; border-color: #d0d5dd; }

.flash {
  margin-bottom: 1rem;
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  background: #fff;
}

.flash-notice { border-color: #bfe8cd; background: #f4fff8; }
.flash-alert { border-color: #f6c8c1; background: #fff7f6; }

.error-box {
  border: 1px solid #f4c3bc;
  background: #fff6f5;
  padding: 0.75rem;
  border-radius: var(--radius-sm);
  margin-bottom: 0.8rem;
}

@media (max-width: 900px) {
  .grid-3,
  .grid-4,
  .grid-2,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .page-head {
    align-items: start;
  }
}

.landing-hero {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid var(--line);
  background: linear-gradient(160deg, #fff7ec 0%, #fef3e3 45%, #ebf9f4 100%);
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 1rem;
}

.landing-aurora {
  position: absolute;
  inset: -20%;
  pointer-events: none;
  background:
    radial-gradient(38% 24% at 18% 20%, rgba(225, 111, 53, 0.26), transparent 72%),
    radial-gradient(32% 24% at 82% 32%, rgba(0, 130, 112, 0.25), transparent 70%),
    radial-gradient(32% 20% at 46% 75%, rgba(40, 126, 196, 0.18), transparent 74%);
  animation: landing-float 14s ease-in-out infinite alternate;
}

.landing-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 1rem;
  align-items: stretch;
}

.landing-kicker {
  display: inline-flex;
  margin: 0 0 0.65rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: #ffffffc9;
  border: 1px solid #ecdcc3;
  color: #7a4d1f;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.landing-hero h1 {
  font-size: clamp(2rem, 5vw, 3.3rem);
  line-height: 1.06;
  margin-bottom: 0.7rem;
}

.landing-lead {
  font-size: 1.02rem;
  line-height: 1.7;
  max-width: 68ch;
  color: #344054;
}

.landing-actions {
  display: flex;
  gap: 0.6rem;
  margin-top: 1rem;
}

.landing-proof ul {
  margin: 0.65rem 0 0;
  padding-left: 1.1rem;
}

.landing-proof li {
  margin: 0.45rem 0;
  color: #344054;
}

.landing-section h2 {
  margin-bottom: 0.85rem;
}

.landing-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.landing-columns h3 {
  margin-bottom: 0.45rem;
  font-size: 1.12rem;
}

.landing-columns ul {
  margin: 0;
  padding-left: 1.1rem;
}

.landing-columns li {
  margin: 0.28rem 0;
}

@keyframes landing-float {
  0% { transform: translateY(0) scale(1); }
  100% { transform: translateY(-16px) scale(1.03); }
}

@media (max-width: 900px) {
  .landing-hero {
    padding: 1.25rem;
  }

  .landing-grid,
  .landing-columns {
    grid-template-columns: 1fr;
  }
}
