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

body {
  font-family: 'Segoe UI', sans-serif;
  background: #f0f4f0;
  color: #1a1a1a;
  min-height: 100vh;
}

.page { max-width: 800px; margin: 0 auto; padding: 40px 20px 60px; }

/* Header */
.header { text-align: center; margin-bottom: 36px; }
.header h1 { font-size: 2rem; font-weight: 800; color: #1b5e20; }
.subtitle { color: #666; margin-top: 6px; font-size: 0.95rem; }
.org-fullname { color: #1b5e20; margin-top: 4px; font-size: 1rem; font-weight: 600; }

/* Logo bar (login & registration pages) */
.logo-bar {
  display: flex; justify-content: center; align-items: center;
  gap: 20px; margin-bottom: 18px;
}
.logo-main {
  width: 110px; height: 110px; border-radius: 50%;
  object-fit: cover; box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.logo-side {
  width: 72px; height: auto; border-radius: 6px;
  object-fit: contain; box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

/* Dashboard logos */
.dashboard-title-block { display: flex; flex-direction: column; }
.dashboard-logos {
  display: flex; align-items: center; gap: 12px; margin-bottom: 10px;
}
.dash-logo-main {
  width: 56px; height: 56px; border-radius: 50%;
  object-fit: cover; box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.dash-logo-side {
  width: 44px; height: auto; border-radius: 4px;
  object-fit: contain; box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}

/* Form card */
.form-card {
  background: white; border-radius: 14px; padding: 32px;
  border: 1px solid #dce8dc; box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.form-row { display: flex; gap: 16px; margin-bottom: 18px; }
.field { flex: 1; margin-bottom: 18px; }
.field label {
  display: block; font-size: 0.78rem; font-weight: 700;
  color: #555; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 6px;
}
.field input, .field select {
  width: 100%; padding: 10px 14px; border: 1px solid #ccd9cc;
  border-radius: 8px; font-size: 0.92rem; color: #1a1a1a;
  background: #fafff a; outline: none; font-family: inherit;
  transition: border-color 0.2s;
}
.field input:focus, .field select:focus { border-color: #1b5e20; }

/* Refund policy notice */
.refund-policy {
  background: #fff8e1; border: 1px solid #ffe082; border-radius: 8px;
  padding: 12px 14px; margin-bottom: 14px; font-size: 0.8rem; color: #5d4037; line-height: 1.5;
}

/* Privacy policy section */
.privacy-policy {
  background: white; border-radius: 12px; padding: 20px 24px;
  border: 1px solid #e0e0e0; margin-top: 20px; font-size: 0.8rem; color: #666; line-height: 1.6;
}
.privacy-policy h3 {
  font-size: 0.85rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em; color: #1b5e20; margin-bottom: 8px;
}
.privacy-policy p { margin-top: 0; }

/* Fee display inside registration form */
.fee-display {
  background: #f1f8f1; border: 1px solid #a5d6a7; border-radius: 10px;
  padding: 14px 18px; margin-bottom: 18px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.fee-label { font-size: 0.85rem; color: #555; font-weight: 600; }
.fee-amount { font-size: 1.4rem; font-weight: 900; color: #1b5e20; }
.fee-note { font-size: 0.75rem; color: #888; margin-left: auto; }
.admin-fee-note { font-size: 0.78rem; color: #777; margin-top: 4px; text-align: right; font-style: italic; }

/* Heritage checkbox */
.heritage-check {
  background: #f1f8f1; border: 1px solid #a5d6a7; border-radius: 8px;
  padding: 14px 16px; margin-bottom: 24px;
}
.checkbox-label { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; }
.checkbox-label input[type="checkbox"] { width: 18px; height: 18px; margin-top: 2px; cursor: pointer; }
.checkbox-label span { font-size: 0.9rem; color: #1b5e20; font-weight: 500; line-height: 1.5; }

/* Buttons */
.btn-submit {
  width: 100%; background: #1b5e20; color: white; border: none;
  padding: 14px; border-radius: 10px; font-size: 1rem; font-weight: 700;
  cursor: pointer; font-family: inherit; transition: background 0.2s;
}
.btn-submit:hover { background: #2e7d32; }

.btn-another {
  background: white; color: #1b5e20; border: 2px solid #1b5e20;
  padding: 10px 24px; border-radius: 8px; font-size: 0.9rem;
  font-weight: 600; cursor: pointer; margin-top: 16px;
}

/* Confirmation */
.confirmation {
  text-align: center; background: white; border-radius: 14px;
  padding: 56px 24px; border: 1px solid #dce8dc;
}
.confirmation .tick { font-size: 3rem; margin-bottom: 16px; }
.confirmation h2 { font-size: 1.6rem; font-weight: 800; color: #1b5e20; margin-bottom: 10px; }
.confirmation p { color: #555; line-height: 1.6; }

/* Admin link */
.admin-link { text-align: center; margin-top: 32px; }
.admin-link a { font-size: 0.85rem; color: #888; text-decoration: none; }
.admin-link a:hover { color: #1b5e20; }

/* Dashboard */
.dashboard-header {
  display: flex; justify-content: space-between; align-items: flex-start;
  margin-bottom: 28px; flex-wrap: wrap; gap: 16px;
}
.dashboard-header h1 { font-size: 1.6rem; font-weight: 800; color: #1b5e20; }
.dashboard-actions { display: flex; gap: 10px; align-items: center; }

.btn-refresh {
  background: white; color: #1b5e20; border: 1px solid #1b5e20;
  padding: 9px 16px; border-radius: 8px; font-size: 0.88rem;
  font-weight: 700; cursor: pointer; font-family: inherit;
}
.btn-refresh:hover { background: #f1f8f1; }

.btn-export {
  background: #1b5e20; color: white; text-decoration: none;
  padding: 9px 18px; border-radius: 8px; font-size: 0.88rem; font-weight: 700;
}
.btn-export:hover { background: #2e7d32; }

.btn-logout {
  background: white; color: #888; border: 1px solid #ddd;
  padding: 9px 16px; border-radius: 8px; font-size: 0.88rem; cursor: pointer;
}

/* Filters */
.filters {
  display: flex; gap: 12px; align-items: center; margin-bottom: 20px; flex-wrap: wrap;
}
.filters select {
  padding: 8px 12px; border: 1px solid #ccd9cc; border-radius: 8px;
  font-size: 0.88rem; color: #1a1a1a; background: white; outline: none;
}
.reg-count { font-size: 0.85rem; color: #888; margin-left: auto; }

/* Registration cards */
.reg-card {
  background: white; border-radius: 10px; padding: 18px 20px;
  border: 1px solid #dce8dc; margin-bottom: 10px;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  flex-wrap: wrap;
}
.reg-card.approved { border-left: 4px solid #2e7d32; }
.reg-card.rejected { border-left: 4px solid #c62828; opacity: 0.6; }
.reg-card.pending { border-left: 4px solid #e07b00; }

.reg-info { flex: 1; }
.reg-name { font-weight: 700; font-size: 1rem; color: #1a1a1a; margin-bottom: 4px; }
.reg-details { font-size: 0.82rem; color: #666; }
.reg-details span { margin-right: 12px; }

.reg-badge {
  font-size: 0.75rem; font-weight: 700; padding: 3px 10px;
  border-radius: 20px; white-space: nowrap;
}
.badge-pending { background: #fff3e0; color: #e07b00; }
.badge-approved { background: #e8f5e9; color: #2e7d32; }
.badge-rejected { background: #ffebee; color: #c62828; }

.reg-actions { display: flex; gap: 8px; }
.btn-approve {
  background: #2e7d32; color: white; border: none;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-reject {
  background: white; color: #c62828; border: 1px solid #c62828;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-approve:hover { background: #1b5e20; }
.btn-reject:hover { background: #c62828; color: white; }

.empty { color: #aaa; text-align: center; padding: 40px; }
.error-msg { color: #c62828; font-size: 0.88rem; margin-bottom: 12px; }

.division-group { margin-bottom: 28px; }
.division-title {
  font-size: 0.78rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.08em; color: #1b5e20; margin-bottom: 10px;
  padding-bottom: 6px; border-bottom: 2px solid #a5d6a7;
}

/* Payment page */
.pay-info-card { text-align: center; }
.pay-player-name { font-size: 1.4rem; font-weight: 800; color: #1a1a1a; margin-bottom: 6px; }
.pay-details { font-size: 0.9rem; color: #666; margin-bottom: 12px; }
.pay-details span { margin: 0 8px; }
.pay-amount {
  font-size: 2.2rem; font-weight: 900; color: #1b5e20;
  background: #f1f8f1; border-radius: 10px; padding: 12px 24px;
  display: inline-block; margin-top: 4px;
}

/* Copy link button */
.btn-copy-link {
  background: #f5f5f5; color: #555; border: 1px solid #ddd;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-copy-link:hover { background: #e8e8e8; }

/* File upload fields */
.field input[type="file"] {
  width: 100%; padding: 10px 12px; border: 2px dashed #ccd9cc;
  border-radius: 8px; font-size: 0.88rem; color: #555;
  background: #fafafa; cursor: pointer; font-family: inherit;
}
.field input[type="file"]:hover { border-color: #1b5e20; }
.field-hint {
  display: block; margin-top: 5px; font-size: 0.78rem;
  color: #888; line-height: 1.4;
}

/* Photo thumbnail in admin cards */
.reg-photo-thumb {
  width: 52px; height: 52px; border-radius: 8px;
  object-fit: cover; flex-shrink: 0;
  border: 2px solid #dce8dc; cursor: pointer;
}
.reg-photo-thumb:hover { border-color: #1b5e20; }
.reg-photo-empty {
  width: 52px; height: 52px; border-radius: 8px; background: #f5f5f5;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  font-size: 0.65rem; color: #bbb; text-align: center; line-height: 1.3;
  border: 2px dashed #ddd;
}

/* Blue Card badges */
.badge-bluecard           { background: #e3f2fd; color: #1565c0; text-decoration: none; cursor: pointer; }
.badge-missing            { background: #ffebee; color: #c62828; }
.badge-bc-unverified      { background: #fff3e0; color: #e07b00; }
.badge-bc-valid           { background: #e8f5e9; color: #2e7d32; }
.badge-bc-invalid         { background: #ffebee; color: #c62828; }

/* Blue Card action buttons */
.btn-bc-valid {
  background: #2e7d32; color: white; border: none;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-bc-valid:hover { background: #1b5e20; }
.btn-bc-invalid {
  background: white; color: #c62828; border: 1px solid #c62828;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-bc-invalid:hover { background: #c62828; color: white; }

/* Auto-division display */
.division-auto-display {
  width: 100%; padding: 10px 14px; border: 2px dashed #ccd9cc;
  border-radius: 8px; font-size: 0.92rem; color: #999; background: #fafafa;
  min-height: 40px; display: flex; align-items: center;
}
.division-auto-display.assigned {
  border: 2px solid #1b5e20; color: #1b5e20; font-weight: 700; background: #f1f8f1;
}

/* Collapsible groups */
.division-title { cursor: pointer; user-select: none; position: relative; }
.toggle-icon { float: right; font-size: 0.75rem; color: #1b5e20; }
.group-content { }

/* Tabs */
.tab-bar {
  display: flex; gap: 4px; margin-bottom: 20px;
  border-bottom: 2px solid #dce8dc;
}
.tab-btn {
  background: none; border: none; padding: 10px 20px;
  font-size: 0.92rem; font-weight: 600; color: #888;
  cursor: pointer; border-bottom: 3px solid transparent;
  margin-bottom: -2px; font-family: inherit;
}
.tab-btn.active { color: #1b5e20; border-bottom-color: #1b5e20; }
.tab-btn:hover { color: #1b5e20; }

/* Badges row */
.reg-badges { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.badge-fee { background: #e3f2fd; color: #1565c0; }
.badge-paid { background: #e8f5e9; color: #2e7d32; }
.badge-unpaid { background: #fff3e0; color: #e07b00; }
.badge-selected { background: #1b5e20; color: white; }
.badge-not-selected { background: #ffebee; color: #c62828; }

/* Selection & payment action buttons */
.btn-select {
  background: #1b5e20; color: white; border: none;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-select:hover { background: #2e7d32; }
.btn-not-select {
  background: white; color: #c62828; border: 1px solid #c62828;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-not-select:hover { background: #c62828; color: white; }
.btn-paid {
  background: #1565c0; color: white; border: none;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-paid:hover { background: #1976d2; }
.btn-reset {
  background: white; color: #888; border: 1px solid #ccc;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-delete {
  background: white; color: #c62828; border: 1px solid #ef9a9a;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
  margin-left: auto;
}
.btn-delete:hover { background: #ffebee; }

.btn-edit {
  background: white; color: #1565c0; border: 1px solid #90caf9;
  padding: 7px 14px; border-radius: 6px; font-size: 0.82rem; cursor: pointer;
}
.btn-edit:hover { background: #e3f2fd; }

/* Edit modal */
.edit-modal-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5);
  z-index: 1000; justify-content: center; align-items: center; padding: 16px;
}
.edit-modal-box {
  background: white; border-radius: 12px; width: 100%; max-width: 600px;
  max-height: 90vh; overflow-y: auto; box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}
.edit-modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 24px 16px; border-bottom: 1px solid #eee;
}
.edit-modal-header h3 { margin: 0; color: #1b5e20; font-size: 1.1rem; }
.edit-modal-close {
  background: none; border: none; font-size: 1.2rem; cursor: pointer; color: #888; padding: 4px 8px;
}
.edit-modal-close:hover { color: #333; }
.edit-modal-form { padding: 20px 24px; }
.edit-row { display: flex; gap: 16px; margin-bottom: 14px; }
.edit-field { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.edit-field label { font-size: 0.8rem; font-weight: 600; color: #555; text-transform: uppercase; letter-spacing: 0.04em; }
.edit-field input, .edit-field select {
  border: 1px solid #ddd; border-radius: 6px; padding: 8px 10px; font-size: 0.9rem; width: 100%; box-sizing: border-box;
}
.edit-field input:focus, .edit-field select:focus { outline: none; border-color: #1b5e20; }
.edit-modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; padding-top: 16px; border-top: 1px solid #eee; }

/* Registration summary table */
.summary-table-wrap { overflow-x:auto; margin-bottom:20px; }
.summary-table { width:100%; border-collapse:collapse; font-size:0.85rem; background:white; border-radius:10px; overflow:hidden; box-shadow:0 2px 8px rgba(0,0,0,0.06); }
.summary-table th { background:#1b5e20; color:white; padding:10px 14px; text-align:left; font-size:0.78rem; text-transform:uppercase; letter-spacing:0.05em; }
.summary-table td { padding:9px 14px; border-bottom:1px solid #f0f0f0; }
.summary-table tbody tr:hover { background:#f9f9f9; }
.summary-total-row td { font-weight:800; background:#f1f8f1; border-top:2px solid #1b5e20; }
.sum-warn { color:#e65100; font-weight:700; }
.sum-all-good { color:#1b5e20; font-weight:700; }

/* Bulk approve button */
.btn-bulk-approve {
  background:#e8f5e9; color:#1b5e20; border:1px solid #a5d6a7;
  padding:4px 10px; border-radius:6px; font-size:0.75rem; font-weight:700; cursor:pointer;
}
.btn-bulk-approve:hover { background:#c8e6c9; }

/* Duplicate badge */
.badge-duplicate { background:#e65100; color:white; }

/* Payment summary cards */
.summary-cards {
  display: flex; gap: 16px; margin-bottom: 24px; flex-wrap: wrap;
}
.summary-card {
  flex: 1; min-width: 120px; background: white; border-radius: 12px;
  padding: 20px; text-align: center; border: 1px solid #dce8dc;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.summary-card-green { border-color: #a5d6a7; }
.summary-card-orange { border-color: #ffcc80; }
.summary-number { font-size: 1.8rem; font-weight: 800; color: #1b5e20; }
.summary-card-orange .summary-number { color: #e07b00; }
.summary-label { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; color: #888; margin-top: 4px; }

/* Paid card style */
.reg-card.paid { border-left: 4px solid #1565c0; }
.reg-card.unpaid-card { border-left: 4px solid #e07b00; }

/* Apparel compact display */
.apparel-compact-block { padding: 10px 0; }
.apparel-row { display:flex; align-items:baseline; gap:12px; padding:8px 0; border-bottom:1px solid #f0f0f0; }
.apparel-row:last-child { border-bottom:none; }
.apparel-row-label { font-size:0.8rem; font-weight:700; color:#555; text-transform:uppercase; letter-spacing:0.04em; min-width:70px; }
.apparel-row-sizes { display:flex; flex-wrap:wrap; gap:6px; align-items:center; }
.apparel-size-chip { background:#f1f8f1; border:1px solid #c8e6c9; border-radius:6px; padding:3px 8px; font-size:0.82rem; color:#333; }
.apparel-size-chip strong { color:#1b5e20; margin-left:2px; }
.apparel-total-inline { font-size:0.8rem; font-weight:700; color:#1b5e20; margin-left:4px; }

/* Apparel tab */
.apparel-note {
  font-size: 0.82rem; color: #888; margin-bottom: 20px;
  background: #f1f8f1; border-radius: 8px; padding: 10px 14px;
  border: 1px solid #c8e6c9;
}
.apparel-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px;
}
.apparel-card {
  background: white; border-radius: 12px; border: 1px solid #dce8dc;
  overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.apparel-card-title {
  background: #1b5e20; color: white; padding: 12px 16px;
  font-size: 0.85rem; font-weight: 700;
}
.apparel-table {
  width: 100%; border-collapse: collapse; font-size: 0.88rem;
}
.apparel-table thead th {
  background: #f5f5f5; padding: 8px 16px; text-align: left;
  font-size: 0.75rem; text-transform: uppercase; color: #888; font-weight: 700;
}
.apparel-table tbody tr:hover { background: #f9f9f9; }
.apparel-table td { padding: 9px 16px; border-bottom: 1px solid #f0f0f0; }
.apparel-qty { font-weight: 800; color: #1b5e20; text-align: right; }
.apparel-total td { background: #f1f8f1; font-weight: 700; border-top: 2px solid #a5d6a7; }
.apparel-total .apparel-qty { color: #1b5e20; font-size: 1rem; }

@media (max-width: 600px) {
  .form-row { flex-direction: column; }
  .dashboard-header { flex-direction: column; }
  .summary-cards { flex-direction: column; }
}
