@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600&display=swap");

:root {
  color-scheme: light;
  --bg: #f5f3ee;
  --surface: #ffffff;
  --ink: #1f2a2e;
  --muted: #5c6b70;
  --accent: #0b5d4f;
  --accent-soft: #d7ebe6;
  --line: #e2e8e4;
  --shadow: 0 24px 60px rgba(18, 34, 28, 0.15);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 10% -10%, #e2efe8, transparent 60%),
    radial-gradient(900px 500px at 90% 0%, #f3ead6, transparent 55%),
    linear-gradient(180deg, #f6f4ef 0%, #f1f0ea 100%);
  min-height: 100vh;
  padding: 32px;
}

.rep {
  background:
    radial-gradient(1200px 600px at 0% 0%, #eaf4f2, transparent 60%),
    radial-gradient(1000px 600px at 100% 0%, #f6efe1, transparent 55%),
    linear-gradient(180deg, #f8f6f2 0%, #f0f2ef 100%);
}

.rep .page {
  max-width: 980px;
  gap: 24px;
}

.rep header {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px 20px;
  box-shadow: 0 18px 40px rgba(15, 23, 32, 0.08);
}

.rep .logo {
  width: 54px;
  height: 54px;
  border-radius: 14px;
}

.rep h1 {
  margin: 0;
  font-size: clamp(26px, 3.6vw, 40px);
}

.rep .section {
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: 0 16px 36px rgba(15, 23, 32, 0.08);
  border: 1px solid #e6ede9;
}

.rep .section h2 {
  text-transform: none;
  letter-spacing: 0.4px;
  font-size: 19px;
  color: var(--ink);
}

.rep .section-head {
  margin-bottom: 12px;
}

.rep .section-meta {
  font-size: 13px;
}

.rep .form {
  gap: 14px;
}

.rep .input {
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 15px;
}

.rep .button {
  border-radius: 10px;
  padding: 12px 18px;
}

.rep .button-secondary {
  border-radius: 10px;
}

.rep .table-wrap {
  border-radius: 14px;
}

.rep .table th {
  background: #f7f8f6;
}

.rep .pill {
  background: #f4f7f4;
}

.rep .chip[data-status="pending"] {
  background: #f2f4f3;
  color: #6a7570;
  border: 1px solid #e2e8e4;
}

.rep .chip[data-status="viewed"] {
  background: #e6f6ec;
  color: #1d6f3f;
  border: 1px solid #bfe8cf;
}

.rep .chip[data-status="approved"] {
  background: #e2f3f6;
  color: #1b5f6d;
  border: 1px solid #bfe0e7;
}

.rep .pill[data-status="pending"] {
  background: #f2f4f3;
  color: #6a7570;
  border: 1px solid #e2e8e4;
}

.rep .pill[data-status="viewed"] {
  background: #e6f6ec;
  color: #1d6f3f;
  border: 1px solid #bfe8cf;
}

.rep .pill[data-status="approved"] {
  background: #e2f3f6;
  color: #1b5f6d;
  border: 1px solid #bfe0e7;
}

.page {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: var(--ink);
  color: #f9f7f2;
  display: grid;
  place-items: center;
  font-weight: 600;
  letter-spacing: 1px;
}

.logo.logo-image {
  background: #ffffff;
  border: 1px solid var(--line);
  padding: 4px;
}

.logo.logo-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 10px;
}

.brand small {
  display: block;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 11px;
  color: var(--muted);
}

.brand strong {
  font-size: 18px;
  letter-spacing: 0.3px;
}

.status {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 24px;
  align-items: stretch;
}

.copy {
  background: var(--surface);
  border-radius: 24px;
  padding: 32px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 44px);
  letter-spacing: 0.4px;
}

p {
  margin: 0 0 24px;
  color: var(--muted);
  line-height: 1.6;
  font-size: 17px;
}

.meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.meta-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  background: #fbfaf7;
  font-size: 14px;
  color: var(--muted);
}

.panel {
  border-radius: 24px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, #ffffff 0%, #f7f6f1 100%);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: var(--shadow);
}

.panel h2 {
  margin: 0;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.panel-item {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
  font-size: 15px;
}

.panel-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.panel-item span:last-child {
  font-weight: 600;
  color: var(--ink);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

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

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #eff5f1;
  border: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

@media (max-width: 900px) {
  body {
    padding: 20px;
  }

  header {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero {
    grid-template-columns: 1fr;
  }

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

.section {
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid var(--line);
  padding: 24px;
  box-shadow: var(--shadow);
}

.section h2 {
  margin: 0 0 16px;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--muted);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.section-head h2 {
  margin: 0;
}

.error {
  padding: 12px 14px;
  border-radius: 12px;
  background: #ffecec;
  color: #a41515;
  border: 1px solid #f5c2c2;
  font-size: 14px;
}

.section-meta {
  margin: -4px 0 16px;
  color: var(--muted);
  font-size: 14px;
}

.notice {
  padding: 12px 14px;
  border-radius: 12px;
  background: #fff7e6;
  color: #8a5a0a;
  border: 1px solid #f1d9a4;
  font-size: 14px;
  margin-bottom: 16px;
}

.success {
  padding: 12px 14px;
  border-radius: 12px;
  background: #e9f7ef;
  color: #1b6d3a;
  border: 1px solid #bfe6cd;
  font-size: 14px;
  margin-bottom: 16px;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: #ffffff;
}

.table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 14px;
  min-width: 520px;
}

.table th,
.table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  word-break: break-word;
}

.table th {
  background: #f6f5f1;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 12px;
}

.table tbody tr:nth-child(even) {
  background: #fbfaf6;
}

.table tbody tr:hover {
  background: #f0f6f3;
}

.form {
  display: grid;
  gap: 16px;
  max-width: 420px;
}

.form-wide {
  max-width: none;
}

.form-card {
  max-width: 640px;
  width: 100%;
  background: #fbfaf7;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 20px;
  box-shadow: var(--shadow);
}

.field {
  display: grid;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
}

.field.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
}

.field.checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

.input {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  font-size: 15px;
  font-family: inherit;
  background: #ffffff;
  width: 100%;
}

.input.textarea {
  min-height: 140px;
  resize: vertical;
}

.input:focus {
  outline: 2px solid #b9d6c9;
  outline-offset: 1px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  background: var(--accent);
  color: #ffffff;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-decoration: none;
}

.button:hover {
  background: #0a5145;
}

.button-secondary {
  background: #f0f3f1;
  color: var(--ink);
  border: 1px solid var(--line);
}

.button-secondary:hover {
  background: #e6ece8;
}

.button-link {
  background: transparent;
  color: var(--accent);
  border: none;
  padding: 0;
  font-size: 14px;
  cursor: pointer;
}

.rich-text {
  background: #fbfaf6;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px;
}

.rich-text p {
  margin: 0 0 12px;
}

.rich-text p:last-child {
  margin-bottom: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: #eef4f2;
  color: var(--muted);
  font-size: 12px;
}

.doc-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.doc-actions.align-right {
  justify-content: flex-end;
}

.confirm-form {
  display: grid;
  gap: 12px;
  justify-items: start;
}

.confirm-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-start;
  width: 100%;
  flex-wrap: wrap;
}

.confirm-actions .confirm-back {
  margin-left: auto;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 2000;
}

.modal.open {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 18, 20, 0.55);
}

.modal-card {
  position: relative;
  z-index: 1;
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  width: min(900px, 100%);
  max-height: 80vh;
  overflow: auto;
  padding: 20px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
  margin-bottom: 12px;
}

.modal-header h2 {
  margin: 0;
  font-size: 18px;
}

.modal-body h3 {
  margin: 16px 0 8px;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--muted);
}
