/* Racing Oil - Business Users frontend CSS */

/* ===== Modal ===== */
.robu-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.robu-modal[hidden] { display: none; }

.robu-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  cursor: pointer;
}

.robu-modal__dialog {
  position: relative;
  background: #fff;
  border-radius: 0.75rem;
  padding: 2rem;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  z-index: 1;
}

.robu-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2rem;
  height: 2rem;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: #9ca3af;
  cursor: pointer;
  border-radius: 0.25rem;
  transition: all 150ms ease;
}

.robu-modal__close:hover {
  color: #1f2937;
  background: #f3f4f6;
}

.robu-modal__title {
  font-family: var(--font-heading, sans-serif);
  font-weight: 700;
  font-style: italic;
  text-transform: uppercase;
  color: var(--color-primary, #001689);
  font-size: 1.5rem;
  margin: 0 0 0.25rem;
}

.robu-modal__subtitle {
  color: #6b7280;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

/* ===== Forms ===== */
.robu-login-form,
[data-robu-profile-form] {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.robu-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.robu-field label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #374151;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.robu-field input {
  padding: 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  font-size: 1rem;
  font-family: inherit;
  background: #fff;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.robu-field input:focus {
  outline: none;
  border-color: var(--color-primary, #001689);
  box-shadow: 0 0 0 3px rgba(0, 22, 137, 0.1);
}

.robu-field input:disabled {
  background: #f9fafb;
  color: #6b7280;
  cursor: not-allowed;
}

.robu-btn-primary {
  padding: 0.75rem 1.5rem;
  background: var(--color-primary, #001689);
  color: #fff;
  border: none;
  border-radius: 0.375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 150ms ease;
  font-family: inherit;
  font-size: 1rem;
}

.robu-btn-primary:hover:not(:disabled) { background: #000d52; }
.robu-btn-primary:disabled { opacity: 0.6; cursor: wait; }

.robu-btn-primary--small {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.robu-btn-secondary {
  padding: 0.5rem 1rem;
  background: #f3f4f6;
  color: #374151;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  cursor: pointer;
  font-size: 0.875rem;
  font-family: inherit;
}

.robu-btn-secondary:hover { background: #e5e7eb; }

.robu-error {
  padding: 0.75rem;
  background: #fee2e2;
  border: 1px solid #fca5a5;
  border-radius: 0.375rem;
  color: #b91c1c;
  font-size: 0.875rem;
}

/* ===== Business Area ===== */
.robu-area {
  max-width: 720px;
  margin: 3rem auto;
  padding: 0 1rem;
}

.robu-area--login {
  max-width: 420px;
  background: #fff;
  padding: 2rem;
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.robu-area__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.robu-area__header h1 {
  font-family: var(--font-heading, sans-serif);
  font-weight: 700;
  font-style: italic;
  text-transform: uppercase;
  color: var(--color-primary, #001689);
  font-size: 1.75rem;
  margin: 0;
}

.robu-area__profile {
  background: #fff;
  padding: 2rem;
  border-radius: 0.5rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.robu-profile-status {
  display: inline-block;
  margin-left: 0.75rem;
  font-size: 0.875rem;
  color: #16a34a;
}

/* ===== Protected document link ===== */
.robu-doc-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  transition: all 150ms ease;
  text-decoration: none;
  color: inherit;
  margin-bottom: 0.5rem;
}

.robu-doc-link:hover:not(.robu-doc-link--locked) {
  border-color: var(--color-primary, #001689);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.robu-doc-link--locked {
  background: #f9fafb;
  border-color: #e5e7eb;
}

.robu-doc-link__lock {
  font-size: 1.25rem;
  flex-shrink: 0;
}

.robu-doc-link__info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.robu-doc-link__name {
  font-weight: 600;
  color: #1f2937;
}

.robu-doc-link__meta {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.125rem;
}
