/* PIQ Access Portal — minimal styles, no framework */

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #f0f2f5;
  color: #1a1a2e;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1rem;
}

header {
  width: 100%;
  max-width: 720px;
  margin-bottom: 2rem;
}

header h1 { font-size: 1.4rem; font-weight: 600; color: #003366; }
header p  { font-size: 0.85rem; color: #555; margin-top: 0.25rem; }

.card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  padding: 2rem;
  width: 100%;
  max-width: 720px;
  margin-bottom: 1.5rem;
}

.card h2 {
  font-size: 1rem;
  font-weight: 600;
  color: #003366;
  border-bottom: 2px solid #e8ecf0;
  padding-bottom: 0.5rem;
  margin-bottom: 1.25rem;
}

.field-row {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.field-row label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  display: block;
  margin-bottom: 0.25rem;
}

.field-value {
  font-size: 0.95rem;
  color: #1a1a2e;
  background: #f7f9fc;
  border: 1px solid #e0e4ea;
  border-radius: 4px;
  padding: 0.4rem 0.7rem;
  display: inline-block;
  min-width: 180px;
}

.field-block { flex: 1; min-width: 160px; }

.username-preview {
  font-family: monospace;
  font-size: 1rem;
  font-weight: 700;
  color: #003366;
}

/* Checkbox / radio grid */
.check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.6rem;
}

.check-grid label, .radio-row label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  cursor: pointer;
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
  border: 1px solid #e0e4ea;
  background: #fafbfc;
  transition: background 0.1s;
}

.check-grid label:hover, .radio-row label:hover { background: #eef2f8; }
.check-grid input, .radio-row input { flex-shrink: 0; }

.radio-row {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Textarea */
textarea {
  width: 100%;
  border: 1px solid #d0d5dd;
  border-radius: 4px;
  padding: 0.6rem 0.75rem;
  font-size: 0.9rem;
  font-family: inherit;
  resize: vertical;
  min-height: 100px;
  margin-top: 0.5rem;
}

textarea:focus { outline: none; border-color: #003366; box-shadow: 0 0 0 2px rgba(0,51,102,0.15); }

/* Submit button */
.btn-primary {
  background: #003366;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 0.7rem 1.8rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-primary:hover    { background: #00509e; }
.btn-primary:disabled { background: #8fa3bc; cursor: not-allowed; }

.btn-secondary {
  background: transparent;
  color: #003366;
  border: 1px solid #003366;
  border-radius: 4px;
  padding: 0.65rem 1.6rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  margin-left: 0.75rem;
}

.btn-secondary:hover { background: #eef2f8; }

/* Status messages */
#submit-status { margin-top: 1rem; font-size: 0.9rem; }
#submit-status.error { color: #c0392b; }

/* Sign-in page */
.signin-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 3rem 1rem;
  text-align: center;
}

.signin-center h2 { font-size: 1.3rem; font-weight: 600; color: #003366; margin-bottom: 0.75rem; }
.signin-center p  { color: #555; margin-bottom: 1.5rem; max-width: 360px; }

.btn-microsoft {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: #0078d4;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 0.7rem 1.4rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-microsoft:hover { background: #005a9e; }

/* Success panel */
#success-panel {
  display: none;
  text-align: center;
  padding: 2rem;
}

#success-panel h2 { color: #155724; margin-bottom: 1rem; }
#success-panel p  { color: #444; margin-bottom: 0.75rem; }
#success-panel a  { color: #003366; word-break: break-all; }

/* Note text */
.note {
  font-size: 0.78rem;
  color: #777;
  margin-top: 0.4rem;
}

/* Status page */
.status-badge {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.status-badge.pending  { background: #fff3cd; color: #856404; }
.status-badge.approved { background: #d4edda; color: #155724; }
.status-badge.rejected { background: #f8d7da; color: #721c24; }
