/* GmailSetor - Clean white + light blue mobile-first */

:root {
  --primary: #ffffff;
  --accent: #3b82f6;
  --accent-light: #eff6ff;
  --accent-dark: #2563eb;
  --text: #1e293b;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --success: #22c55e;
  --danger: #ef4444;
  --warning: #f59e0b;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,0.08);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

body {
  font-family: var(--font);
  background: #f8fafc;
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
  padding-bottom: 70px; /* space for bottom nav */
}

a {
  color: var(--accent);
  text-decoration: none;
}

/* Header */
.app-header {
  background: var(--primary);
  border-bottom: 1px solid var(--border);
  padding: 14px 16px;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.app-header .logo {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--accent);
}

.app-header .user-info {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Desktop nav */
.desktop-nav {
  display: none;
  gap: 8px;
}

.desktop-nav a {
  padding: 8px 14px;
  border-radius: 8px;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 500;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  background: var(--accent-light);
  color: var(--accent);
}

/* Bottom navigation (mobile) */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--primary);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
  z-index: 100;
}

.bottom-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.7rem;
  color: var(--text-muted);
  padding: 4px 8px;
  min-width: 56px;
}

.bottom-nav a.active {
  color: var(--accent);
}

.bottom-nav .icon {
  font-size: 1.35rem;
  margin-bottom: 2px;
}

/* Container */
.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 16px;
}

/* Cards */
.card {
  background: var(--primary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}

.card-muted {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s;
  text-align: center;
  width: 100%;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-dark);
}

.btn-success {
  background: var(--success);
  color: #fff;
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.85rem;
  width: auto;
}

/* Status badges */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-pending { background: #fef3c7; color: #b45309; }
.badge-success { background: #dcfce7; color: #15803d; }
.badge-danger  { background: #fee2e2; color: #b91c1c; }
.badge-info    { background: var(--accent-light); color: var(--accent); }
.badge-muted   { background: #f1f5f9; color: var(--text-muted); }

/* Data display */
.data-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}

.data-row:last-child {
  border-bottom: none;
}

.data-label {
  color: var(--text-muted);
}

.data-value {
  font-weight: 600;
  word-break: break-all;
  text-align: right;
  max-width: 60%;
}

/* Balance */
.balance-box {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}

.balance-box .label {
  font-size: 0.85rem;
  opacity: 0.9;
}

.balance-box .amount {
  font-size: 1.75rem;
  font-weight: 700;
  margin: 4px 0;
}

.balance-box .pending {
  font-size: 0.85rem;
  opacity: 0.85;
}

/* Form */
.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--text);
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font-size: 1rem;
  background: #fff;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.checkbox-group input {
  margin-top: 3px;
}

/* Alert */
.alert {
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.alert-success { background: #dcfce7; color: #15803d; }
.alert-danger  { background: #fee2e2; color: #b91c1c; }
.alert-info    { background: var(--accent-light); color: var(--accent-dark); }
.alert-warning { background: #fef3c7; color: #b45309; }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}

.empty-state .icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

/* Loading */
.loading {
  text-align: center;
  padding: 20px;
  color: var(--text-muted);
}

/* Desktop */
@media (min-width: 768px) {
  body {
    padding-bottom: 0;
  }
  .bottom-nav {
    display: none;
  }
  .desktop-nav {
    display: flex;
  }
  .container {
    max-width: 800px;
    padding: 24px;
  }
}

/* Utility */
.text-center { text-align: center; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.fw-bold { font-weight: 600; }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.d-none { display: none !important; }
