/* SSGC Suite — shared styles */
:root {
  --bg: #F3F4EE;
  --primary-green: #0E6B1A;
  --soft-green: #DDF1D8;
  --selected-green: #2E7D32;
  --card: #F8F8F3;
  --text-dark: #1D1D1B;
  --text-muted: #6D7268;
  --grad-start: #0B6A15;
  --grad-end: #4D9458;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text-dark);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-tap-highlight-color: transparent;
}

.page {
  max-width: 720px;
  margin: 0 auto;
  padding: 14px 16px 28px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.header {
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  background: linear-gradient(to right, var(--grad-start), var(--grad-end));
  box-shadow: 0 6px 14px rgba(0,0,0,0.08);
  text-align: center;
  color: white;
  position: relative;
}

.header h1 {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.header p {
  margin: 6px 0 0;
  font-size: 14px;
  line-height: 1.35;
  color: #D9E7D7;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-row .title-block {
  flex: 1;
}

.icon-btn {
  background: rgba(255,255,255,0.12);
  border: none;
  color: white;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  text-decoration: none;
}
.icon-btn:active { background: rgba(255,255,255,0.25); }

.card {
  background: var(--card);
  border-radius: var(--radius-md);
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  padding: 14px 16px;
}

.summary-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.summary-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--soft-green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: var(--primary-green);
  flex-shrink: 0;
}

.summary-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.summary-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin: 2px 0 0;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 52px;
  border-radius: var(--radius-md);
  border: none;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  background: var(--card);
  color: var(--text-dark);
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}
.btn:active { transform: scale(0.98); }
.btn.primary { background: var(--selected-green); color: white; }
.btn.muted { color: var(--primary-green); }
.btn-row { display: flex; gap: 10px; }
.btn-row > .btn { flex: 1; }

.fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--selected-green);
  color: white;
  font-size: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(0,0,0,0.2);
  border: none;
  cursor: pointer;
}

a { color: inherit; text-decoration: none; }

.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 20px;
  font-size: 15px;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #2b2b29;
  color: white;
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 14px;
  box-shadow: 0 6px 14px rgba(0,0,0,0.25);
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
  max-width: 90%;
  text-align: center;
}
.toast.show { opacity: 1; }

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 900;
}

.modal {
  background: white;
  border-radius: var(--radius-md);
  padding: 20px;
  max-width: 420px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
}

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

.modal .actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.text-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 15px;
  font-weight: 600;
  padding: 10px 14px;
  cursor: pointer;
}

.filled-btn {
  background: var(--primary-green);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

input[type="text"], input[type="number"], input[type="email"], input[type="password"], select {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #ddd;
  background: #f5f5f0;
  font-size: 15px;
  color: var(--text-dark);
}
input:focus, select:focus { outline: 2px solid var(--selected-green); }

.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  font-size: 15px;
}

.section-title {
  font-weight: 700;
  margin: 18px 0 8px;
  font-size: 15px;
}

.spinner {
  width: 28px;
  height: 28px;
  border: 3px solid var(--soft-green);
  border-top-color: var(--primary-green);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 40px auto;
}
@keyframes spin { to { transform: rotate(360deg); } }
