.age-workspace {
  flex: 1;
  display: grid;
  grid-template-columns: 320px 1fr 280px;
  gap: 0;
  min-height: 0;
}

.age-panel,
.age-side {
  background: var(--surface);
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  overflow-y: auto;
}

.age-panel { border-right: 1px solid var(--border); }
.age-side { border-left: 1px solid var(--border); }

.age-main {
  padding: 22px 22px;
  overflow-y: auto;
  background: linear-gradient(180deg, rgba(79, 70, 229, 0.04), transparent 42%), var(--bg);
}

section {
  padding: 14px 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
}

.section-label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text3);
  margin-bottom: 10px;
}

.section-label-inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.hint-text {
  font-size: 12px;
  color: var(--text3);
  margin-top: 8px;
  line-height: 1.65;
}

.hint-text--warn {
  color: #ef4444;
  font-weight: 600;
}

.mode-row {
  display: flex;
  gap: 8px;
}

.mode-btn {
  flex: 1;
  padding: 10px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-muted);
  color: var(--text2);
  cursor: pointer;
  transition: all 0.2s var(--ease);
  font-weight: 500;
  font-size: 13px;
}

.mode-btn:hover {
  border-color: var(--border-strong);
  color: var(--text);
}

.mode-btn.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

.input-label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text2);
  margin-bottom: 8px;
}

.text-input {
  width: 100%;
  padding: 10px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.text-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.btn-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.select {
  width: 100%;
  padding: 10px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-family: var(--sans);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.field-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field > span {
  font-size: 12px;
  color: var(--text2);
  font-weight: 500;
}

.field--switch {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 10px;
  background: var(--surface-muted);
  margin-top: 22px;
}

.field--switch span {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  color: var(--text2);
  font-weight: 500;
}

.field--switch input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: var(--surface-muted);
  color: var(--text2);
}

.status-badge.is-neutral {
  background: #eef2f7;
  color: #526072;
}

.status-badge.is-loading {
  background: #e0f2fe;
  color: #0369a1;
}

.status-badge.is-success {
  background: #dcfce7;
  color: #15803d;
}

.status-badge.is-danger {
  background: #fee2e2;
  color: #b91c1c;
}

.message-block {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--surface-muted);
  color: var(--text2);
  line-height: 1.7;
}

.is-hidden { display: none; }

.result-card {
  border-radius: 18px;
  padding: 18px 18px;
  background:
    radial-gradient(circle at top left, rgba(79, 70, 229, 0.12), transparent 48%),
    radial-gradient(circle at top right, rgba(6, 182, 212, 0.12), transparent 44%),
    var(--surface);
}

.result-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text3);
}

.result-age {
  margin-top: 10px;
  font-size: 48px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.result-detail {
  margin-top: 10px;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
}

.meta-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  background: transparent;
  border: none;
  padding: 0;
}

.meta-card {
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.75);
  padding: 14px 14px;
  backdrop-filter: blur(6px);
}

.meta-label {
  font-size: 12px;
  color: var(--text3);
  font-weight: 500;
}

.meta-value {
  margin-top: 8px;
  font-size: 14px;
  font-family: var(--mono);
  color: var(--text);
}

.note-box {
  padding: 14px 14px;
  border-radius: 16px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  margin-top: 10px;
}

.note-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
}

.note-text {
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--text3);
}

@media (max-width: 980px) {
  .age-workspace {
    grid-template-columns: 1fr;
  }
  .age-panel { border-right: none; border-bottom: 1px solid var(--border); }
  .age-side { border-left: none; border-top: 1px solid var(--border); }
  .meta-grid { grid-template-columns: 1fr; }
}
